[Dovecot] ntp revisited (so what to do ?)

Ed W lists at wildgooses.com
Tue May 10 16:50:41 EEST 2011


On 09/05/2011 08:57, Stan Hoeppner wrote:
> On 5/9/2011 1:31 AM, Per Jessen wrote:
>> Stan Hoeppner wrote:
> 
>>> This is not correct.  You're assuming that ntpd doesn't perform sanity
>>> checks on the system time when the daemon starts, which is not the
>>> case.
>>
>> The sanity check may be disabled with -g in which case using
>> ntpdate/sntp/ntpd -q at start up becomes pointless.
> 
> 'ntpdate -q' has always been 'pointless', unless you just want to look
> at the offset without modifying the clock.  I do so on occasion to see
> how accurately my local ntp server is keeping time.  For instance:

Can I suggest that the OP also consider Chrony for timekeeping needs?

Chrony will generally sync faster than ntp and additionally will manage
the setting of the clock at startup.  Even nicer it will condition the
RTC clock and so for example if your RTC is drifting (it will) then
chrony tries to maintain a drift estimate and set the initial time to a
sensible offset from the RTC (nice!)

Chrony just made a new release a few days ago and it has a bunch of neat
features for those who want to get excited about excessively accurate clocks


> I acquired 'special' permission many years ago to use a few stratum 1
> USNO servers mostly because at that time I lived in a city where one of
> them is located, and because I only have one client querying
> infrequently.  USNO is the official time keeper for the US Military and
> the US Government, including ships at sea via GPS.  USNO has the most
> accurate timekeeping devices on the planet--atomic clocks.  Most (if not
> all) of the stratum 2 servers in the US query the USNO stratum 1 servers.

Querying an NTP stratum 1 server over the internet will likely leave you
with less than millisec accuracy.  ie the original is accurate, but the
limitations of syncing over the internet are significant

Compared with a cheap GPS attached to your machine which should get
below ms accuracy and perhaps even below the 100us mark

So, in practice it's fairly irrelevant to be hooked to a stratum 1 for
most purposes and if you really want to get obsessed about accurate time
(I'm going through this obsession phase right now...) then just get a
local GPS attached to your machine...

I saw some analysis from the current lead Chrony developer comparing
time offsets of a bunch of public timeservers and the resulting analysis
seems to be that there is quite some significant skew, even on stratum 1
machines... ie you can easily do better at home with a GPS than using a
public stratume 1... Curious huh

Good luck

Ed W


More information about the dovecot mailing list