[ntp:questions] NTPD silently not tracking
Magnus Danielson
magnus at rubidium.dyndns.org
Fri Aug 30 00:04:24 UTC 2013
Hi,
We had another incident where a node configured with multiple NTP
sources had an NTPD which when asked with ntpdc have peers, looks like
things are all OK, but with offsets less than a second, while the node
in fact was 6 days off the mark. Only on a number of ntpdc querries did
some of the peers expose a gigantic offset. Everything looked OK, but
time was off such that normal remote login did not work.
The error was way to non-obvious and felt like a Heisenbug in that only
when we looked more carefully at it, it started to see itself that it
was out of touch with reality.
We have now designed a script that warns of an error:
cat /etc/cron.hourly/timechecker
#!/bin/bash
awk 'BEGIN {printf "ntpdate -q "} ; $1 == "server" {printf $2" "}; END {print ""}' /etc/ntp.conf | bash | awk '$5 == "adjust" && ( $10 > 1.0 || $10 < -1.0 ) {print "WARNING: timechecker says that time of host is off by "$10" seconds"}'
However, this should be addressed in a much more direct manor by NTPD. Have you seen this before? Do you have a remedy?
ii ntp 1:4.2.6.p5+d i386 Network Time Protocol daemon and
Cheers,
Magnus
More information about the questions
mailing list