Date: Mon, 20 Dec 2010 09:33:22 +1100 From: Mark Andrews <marka@isc.org> To: Jeremy Chadwick <freebsd@jdc.parodius.com> Cc: Dan Allen <danallen46@airwired.net>, dougb@freebsd.org, FreeBSD-STABLE Mailing List <freebsd-stable@freebsd.org> Subject: Re: ntpd fails on boot Message-ID: <20101219223323.111868083B1@drugs.dv.isc.org> In-Reply-To: Your message of "Sat, 18 Dec 2010 14:02:44 -0800." <20101218220244.GA19039@icarus.home.lan> References: <F211F762-1572-4509-9A3D-807E0595C1CD@airwired.net> <20101215004712.GA56065@icarus.home.lan> <E1BBE50E-4FBD-4C91-950D-51EB1102C4D5@airwired.net><20101218220244.GA19039@icarus.home.lan>
next in thread | previous in thread | raw e-mail | index | archive | help
In message <20101218220244.GA19039@icarus.home.lan>, Jeremy Chadwick writes: > On Sat, Dec 18, 2010 at 11:37:21AM -0700, Dan Allen wrote: > > > > On 14 Dec 2010, at 5:47 PM, Jeremy Chadwick wrote: > > > > > Anyway, many people are using the below with success. > > > > Sorry to say that netwait did NOT in the end fix the problem. > > > > I however discovered that if I put > > > > synchronous_dhclient="YES" > > > > into my /etc/rc.conf file, that over many days & reboots now has > > been delivering reliable networking such that ntpd always works. > > > > Thanks again to everyone for their help. > > For DHCP-based clients, yeah, netwait itself isn't sufficient; you'd > need to use synchronous_dhclient as you discovered. > synchronous_dhclient will accomplish the same thing as netwait for > DHCP-based clients. > > Explanation: dhclient will sit and wait until DHCP is fully negotiated > before continuing on with remaining rc scripts. The negotiation > involves packets going back/forth between the client and server on UDP > ports 67 and 68, which obvious acts as a validator that traffic is > flowing across the interface. > > I'll add a comment to the top of the netwait script noting that it > should be used for environments where the system is not using DHCP > (configured static IPs in rc.conf), and mention for DHCP-based clients > to use synchronous_dhclient instead. My solution was to start/re-start ntp using /etc/dhclient-exit-hooks whenever the IP address changed. -- Mark Andrews, ISC 1 Seymour St., Dundas Valley, NSW 2117, Australia PHONE: +61 2 9871 4742 INTERNET: marka@isc.org
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20101219223323.111868083B1>