In check_ntp_sync_by_ssh.py script, you're checking "ntpq -p" result and considering values unit in this result is second.
But on my systems (and blogs I saw on the web), all values unit is millisecond.
Also in comments in your script you say :
# We are looking for a line like
# remote refid st t when poll reach delay offset jitter
#==============================================================================
#127.127.1.0 .LOCL. 10 l 53 64 377 0.000 0.000 0.001
# *blabla blabla 3 u 909 1024 377 0.366 -3.200 5.268
On my systems I got :
root@server21:~# ntpq -p
remote refid st t when poll reach delay offset jitter
==============================================================================
+z.bsod.fr 138.195.130.62 3 u 71 1024 377 306.726 33.223 187.520
+midir.legt.fr 88.190.16.19 3 u 1016 1024 373 123.219 -33.260 109.214
*ns1.admincmd.co 145.238.203.14 2 u 147 1024 377 279.106 -122.38 43.577
I have to use ntpdc -p to get milliseconds values :
Hi,
In check_ntp_sync_by_ssh.py script, you're checking "ntpq -p" result and considering values unit in this result is second.
But on my systems (and blogs I saw on the web), all values unit is millisecond.
Also in comments in your script you say :
On my systems I got :
I have to use ntpdc -p to get milliseconds values :
For information, all my systems are Debian 7 (jessie) with ntpq 4.2.6p5.
See below correction (quite simple ;-)) I made to use milliseconds.
Regards, Marc CESARINE