Re: ntpdate leap year
Greg Madden <email@example.com> writes:
> I use ntp-simpl. This is a leap year, 29 days in February, but ntp is
> short by one day. I can adjust the date manually but when ntp runs it
> sets me back a day. Is there away to tell ntp about leap years ?
First, not to be a wiseass, but you might want to check that the
source you're using to manually set your computer's clock is correct.
Just because your watch says it's March 2 doesn't make it true.
NTP should already know everything it needs to about leap years. If
you're synchronizing to a single NTP server, that server may be
misconfigured (or may have handled the leap year incorrectly).
To see if this is the case, install the "ntpdate" package if you
haven't already. Try setting the correct date and time manually, then
ntpdate -q time.windows.com ntp.gci.net your-ntp-server.wherever.net
This will produce output like:
server 184.108.40.206, stratum 2, offset 0.001581, delay 0.06384
server 220.127.116.11, stratum 3, offset -0.005527, delay 0.06911
server x.x.x.x, stratum 2, offset 0.004713, delay 0.04111
1 Mar 22:48:29 ntpdate: adjust time server 18.104.22.168 offset 0.004713 sec
For each server line, the offset gives the difference, in seconds,
between that server's clock and your machine's clock. If your offset
from known, good servers like "time.windows.com" and "ntp.gci.net" is
a couple of seconds or less but your offset from the server you're
trying to synchronize to is enormous (around 86400 seconds, say), then
that server is misconfigured.
If the server offsets are all just a few seconds, but "date" still
shows a bogus date, something's probably wrong with your timezone
setting. Does "date -R" show an offset of "-0900" at the end, which
should be the correct value for Alaska at this time of year?