israel@qvax2.UUCP ( Renegade@ex2564) (02/24/89)
And the winner of the "spot the rwhod bug" contest is Robert Brazile at {uunet,convex,killer,rize}!brazile, who correctly identified the problem as the following: The rwhod daemon contains a routine called configure(), which reads in the system configuration data looking for network interfaces to exchange status data with. It checks each pertinent driver interface for broadcast or point-to-point communication capability - if the driver flag corresponding to IFF_BROADCAST or IFF_POINTTOPOINT is not set on, the daemon will ignore that interface and go on to look at the next one. The problem for our system appears to be that the "il0" driver we use to talk to our Interlan 1010A Ethernet controller on the Vax 11/750's is not reporting the IFF_BROADCAST flag as being set on. Consequently, the daemon thinks it has nothing to talk to, and hence generates no output status files, even for itself. In examining the driver code, it appears that the IFF_BROADCAST flag is supposed to be set during ioctl SIOCIFADDR calls, used for setting the il0 interface address, as described in INTRO (4N) in the BSD4.2 manuals. Since we can use rlogin, rsh, ftp, and telnet in and out of the 750's, I assume this call is occurring sometime (probably during boot-up procedures). This would seem to indicate that the IFF_BROADCAST flag is probably being cleared by mistake somewhere along the way. Either that, or the ioctl call simply isn't needed to support the other network functions, and so is never actually invoked. If any of you wizard types out there can tell me where I'm losing my IFF_BROADCAST flag, please drop me a line.
chris@mimsy.UUCP (Chris Torek) (02/28/89)
In article <516@qvax2.UUCP> israel@qvax2.UUCP (Renegade@ex2564) writes: > In examining the driver code, it appears that the IFF_BROADCAST flag >is supposed to be set during ioctl SIOCIFADDR calls ... No: it is supposed to be set at boot time, then never cleared. > If any of you wizard types out there can tell me where I'm losing my >IFF_BROADCAST flag, please drop me a line. You must still be running 4.2BSD. (Astounding.) There is a bug in /sys/net/if.c ifioctl(). Under case SIOCSIFFLAGS, there is a line like ifp->if_flags = ifr->ifr_flags; which should in fact read ifp->if_flags = (ifp->if_flags & IFF_CANTCHANGE) | (ifr->ifr_flags &~ IFF_CANTCHANGE); where IFF_CANTCHANGE is #define IFF_CANTCHANGE (IFF_BROADCAST | IFF_POINTOPOINT | IFF_RUNNING) so that /etc/ifconfig (and anyone else) cannot alter these flags. (There should also be a suser() check; I seem to recall that 4.2BSD let anyone configure an interface down.) -- In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 7163) Domain: chris@mimsy.umd.edu Path: uunet!mimsy!chris