From owner-freebsd-questions@FreeBSD.ORG Sat Mar 13 20:22:52 2010 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AE9AB106564A for ; Sat, 13 Mar 2010 20:22:52 +0000 (UTC) (envelope-from m.seaman@infracaninophile.co.uk) Received: from smtp.infracaninophile.co.uk (gate6.infracaninophile.co.uk [IPv6:2001:8b0:151:1::1]) by mx1.freebsd.org (Postfix) with ESMTP id 37E6E8FC18 for ; Sat, 13 Mar 2010 20:22:52 +0000 (UTC) Received: from seedling.black-earth.co.uk (seedling.black-earth.co.uk [81.187.76.163]) (authenticated bits=0) by smtp.infracaninophile.co.uk (8.14.4/8.14.4) with ESMTP id o2DKMj12030473 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Sat, 13 Mar 2010 20:22:46 GMT (envelope-from m.seaman@infracaninophile.co.uk) Message-ID: <4B9BF415.4030006@infracaninophile.co.uk> Date: Sat, 13 Mar 2010 20:22:45 +0000 From: Matthew Seaman Organization: Infracaninophile User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-GB; rv:1.9.1.8) Gecko/20100227 Thunderbird/3.0.3 MIME-Version: 1.0 To: RW References: <3f1c29e71003120257h23ecc310w730bbc6396b27a37@mail.gmail.com> <795fc2b81003120622o2162463dv6697e26a86188cbe@mail.gmail.com> <20100312145405.742da070@gumby.homeunix.com> <3f1c29e71003120706q692fbc1cgebd2463dcf95b35d@mail.gmail.com> <20100312152732.377a92a2@gumby.homeunix.com> <86r5npun1e.fsf@blue.stonehenge.com> <3f1c29e71003130647x8e78411w82fcdde6f1f78479@mail.gmail.com> <4B9BD37E.1060801@infracaninophile.co.uk> <20100313190838.2197cdc8@gumby.homeunix.com> In-Reply-To: <20100313190838.2197cdc8@gumby.homeunix.com> X-Enigmail-Version: 1.0.1 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Virus-Scanned: clamav-milter 0.95.3 at happy-idiot-talk.infracaninophile.co.uk X-Virus-Status: Clean X-Spam-Status: No, score=-1.1 required=5.0 tests=BAYES_00,DKIM_ADSP_ALL, SPF_FAIL autolearn=no version=3.3.0 X-Spam-Checker-Version: SpamAssassin 3.3.0 (2010-01-18) on happy-idiot-talk.infracaninophile.co.uk Cc: freebsd-questions@freebsd.org Subject: Re: ntpdate problem X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 13 Mar 2010 20:22:52 -0000 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 13/03/2010 19:08:38, RW wrote: > ntpd_sync_on_start="YES" > > is not a complete substitute for running ntpdate at startup. It allows > ntpd to make a large correction, but it doesn't block the boot sequence > so you could still get a large step-change later-on when your daemons > are starting-up. Been there, done that and spent many hours cursing dovecot, which just dies on its arse if the clock does anything it doesn't approve of -- the biggest flaw in an otherwise excellent program IMHO. > ntpd has an option to emulate ntpdate, but it holds-up the > boot-sequence much longer - presumably this is why ntpdate has been > deprecated for a long time but hasn't yet gone away. There's a trick that can be used to get round this, which is to use the iburst option within ntp.conf. Some NTP servers don't like having it used against them, and will refuse to serve you, but you only need it on one or two of the server lines in your config file. Eg: server time.example.com iburst maxpoll 10 restrict time.example.com nomodify nopeer noquery notrap (The restrict line is an example of good practice, but strictly irrelevant to this argument.) iburst speeds up the initial synchronisation by sending a sequence of 8 query packets at 2 second intervals, rather than the standard 64s between packets you get otherwise. With this in place I've never had a problem with the clock being stepped after the rest of the system is up and causing mayhem for other programs, nor have I needed to run ntpdate(8) -- it even seems to work for virtual machines that can end up missing many hours when the lappy goes to sleep. Cheers, Matthew - -- Dr Matthew J Seaman MA, D.Phil. 7 Priory Courtyard Flat 3 PGP: http://www.infracaninophile.co.uk/pgpkey Ramsgate Kent, CT11 9PW -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.14 (Darwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkub9BUACgkQ8Mjk52CukIzOfQCbBJfVvtj7gnwwGztSwYZW5HYs khAAn2Y20P6zl54+7WK+KdM3jlrzIbA4 =QYrF -----END PGP SIGNATURE-----