[ntp:questions] ntptime says that clock is unsynchronized

BJörn Lindqvist bjourne at gmail.com
Thu Nov 6 16:07:59 UTC 2008


Hello,

I'm trying to analyze a failure scenario that occurs on a server and
client in my network. First my server, which only synchronizes to the
system clock:

    # ntpq -p
         remote           refid      st t when poll reach   delay
offset  jitter
    ==============================================================================
    *LOCAL(0)        LOCAL(0)        10 l   10   16  377    0.000
0.000   0.001

I *know* that it should have more upstream peers, but that is beside
the point I hope. My client synchronizes to that server just fine:

    # ntpq -p
         remote           refid      st t when poll reach   delay
offset  jitter
    ==============================================================================
     LOCAL(0)        LOCAL(0)        12 l    7   16  377    0.000
0.000   0.001
    *192.168.1.4     LOCAL(0)        11 u   22   64  377    0.118
41.432   0.524

But when I run ntptime on the server, I get this:

    # ntptime
    ntp_gettime() returns code 5 (ERROR)
      time ccbd930d.7cfa6000  Thu, Nov  6 2008 16:00:13.488, (.488195),
      maximum error 16384000 us, estimated error 16 us
    ntp_adjtime() returns code 5 (ERROR)
      modes 0x0 (),
      offset 0.000 us, frequency 0.000 ppm, interval 4 s,
      maximum error 16384000 us, estimated error 16 us,
      status 0x41 (PLL,UNSYNC),
      time constant 0, precision 1.000 us, tolerance 512 ppm,
      pps frequency 0.000 ppm, stability 512.000 ppm, jitter 200.000 us,
      intervals 0, jitter exceeded 0, stability exceeded 0, errors 0.

Why the errors? Return code 5 means that the clock is unsynchronized
but I see no reason for that to happen. It is perfectly synchronized
to the system clock. Maximum error is 16384000 which I think is some
default value? ntptime on the client looks much healthier:

    # ntptime
    ntp_gettime() returns code 0 (OK)
      time ccbd93a3.42335000  Thu, Nov  6 2008 16:02:43.258, (.258595),
      maximum error 6263312 us, estimated error 16 us
    ntp_adjtime() returns code 0 (OK)
      modes 0x0 (),
      offset 0.000 us, frequency -18.108 ppm, interval 4 s,
      maximum error 6263312 us, estimated error 16 us,
      status 0x1 (PLL),
      time constant 0, precision 1.000 us, tolerance 512 ppm,
      pps frequency 0.000 ppm, stability 512.000 ppm, jitter 200.000 us,
      intervals 0, jitter exceeded 0, stability exceeded 0, errors 0.

The system appears to work fine at the moment, but why the strange
ntptime output?

Thanks in advance. Please let me know if you need more information.


-- 
mvh Björn



More information about the questions mailing list