Subject: ifconfig breakage
To: None <current-users@netbsd.org>
From: None <msouth@msouth.ba.ca.us>
List: current-users
Date: 03/06/2000 18:01:28
ifconfig is working the first time through.  The second time you get the
"ifconfig: SIOCDIFADDR: Address family not supported by protocol family"
error.  Which is why dhcp is messing it up--it configures the interface
for dhcp discovery, then tries to do it again and gets the message.

I added a printf to in_control() in netinet/in.c.  When it fails,
ifra->ifra_addr.sin_family is zero, which is AF_UNSPEC, not AF_INET.
Perhaps a bad initialization in ifconfig?

A workaround is to define "options COMPAT_43" in the kernel config file.
If that's defined then in_control() will default AF_UNSPEC to AF_INET.
I tried it and nothing else fell over.

--
Michael South
msouth@scruz.net