Subject: ifstatus problems...
To: None <netbsd-help@netbsd.org>
From: Brian Stark <bstark@siemens-psc.com>
List: netbsd-help
Date: 08/04/1998 14:50:08
All,
Has anyone had any luck with getting ifstatus 2.1 to run properly on
NetBSD 1.3.2?
Each time I try to run it I get the following:
./ifstatus: ioctl: SIOCGIFCONF: Device not configured.
The section of code that issues this message looks like this:
struct ifconf ifc;
struct ifreq ifr, *ifrp;
if ((s = socket(AF_INET, SOCK_DGRAM, 0)) < 0)
fatal("socket", NULL);
ifc.ifc_buf = cbuf;
ifc.ifc_len = sizeof(cbuf);
if (ioctl(s, SIOCGIFCONF, (char *) &ifc) < 0)
fatal("ioctl: SIOCGIFCONF", NULL);
...it looks pretty straight forward, so I am wondering what I am missing.
Even with the generic kernel I get the 'device not configured' message.
Ideas anyone? (and yes, I did set the flags in the Makefile for a BSD
based OS).
Brian
-------------------------------------------------------------------------
| Brian Stark | Internet : bstark@siemens-psc.com |
| Siemens Power Systems Control | |
| 7225 Northland Drive | Voice : +1 612 536-4697 |
| Brooklyn Park, MN 55428 USA | Fax : +1 612 536-4919 |
-------------------------------------------------------------------------