conf/151063: [rc.subr] Verify network link and packet flow before
starting network services
freebsd at jdc.parodius.com
Wed Sep 29 10:00:12 UTC 2010
>Synopsis: [rc.subr] Verify network link and packet flow before starting network services
>Arrival-Date: Wed Sep 29 10:00:11 UTC 2010
>Originator: Jeremy Chadwick
>Release: FreeBSD 8.1-STABLE amd64
System: FreeBSD icarus.home.lan 8.1-STABLE FreeBSD 8.1-STABLE #0: Wed Sep 15 14:59:46 PDT 2010 root at icarus.home.lan:/usr/obj/usr/src/sys/X7SBA_RELENG_8_amd64 amd64
There's a long-standing issue that plagues both users and system administrators
on FreeBSD: network services (named, ntpd, etc.) starting before the actual
network layer is up and fully functional. Monitoring link state according to
ifconfig is not enough -- actual packet flow verification is needed.
I've written a script along with the help of the community and Doug Barton
to help alleviate this problem as best possible. There are better solutions
over the long-term, involving daemons which maintain/spawn services (think
svcs(1) and svcadm(1M) on Solaris), but for now this should be sufficient.
Original discussion thread:
The script is in use by existing community users, and tested by a good number
of people with complex network environments (dual NICs + vlan(4) + NAT) on
both RELENG_7 and RELENG_8. So far it has been used by placing the script
into /usr/local/etc/rc.d followed by setting appropriate vars in /etc/rc.conf:
Patches for rc.conf(5) man page and /etc/defaults/rc.conf:
All of this should be reviewed by someone with familiarity with rc(8).
Please CC Doug Barton <dougb at FreeBSD.org> as well. Thanks!
More information about the freebsd-bugs