[ntp:questions] ntp server help

Unruh unruh-spam at physics.ubc.ca
Sat Aug 9 02:16:28 UTC 2008


mikel at irontec.com (Mikel Jimenez) writes:

>Hello

>I have 4 ip cameras and I configured with ntp server 10.219.229.1, a 
>Debian NTP Server. I am Having problems to synchronize cameras because I 
>need at least 0.01 seconds of offset and I am having more than this 
>value, as you can see in the graphic. Is very important that cameras 
>time be very accuracy . Please help, is for an important project
>I query cameras with this script

And you are using ntpdate why? Why not set up ntp on the system and use it
to discipline your system's clock. Note whether you will get 1/100 sec
accuracy depends on the network etc. 

And why are you comparing the offset? 



>#! /bin/bash
>umbral=0.010000

>dato=$(ntpdate -q $1 | grep ntpdate | grep offset | awk '{ print $10 }')

>verifi=$(echo $umbral $dato| awk '{if ($1 > $2) print "ok"; else print 
>"fail"}')

>if [ $verifi =  "ok" ]; then
>echo "OK ($dato)"
>exit 0
>else
>echo "Too much delay ($dato)"
>exit 1
>fi


>/ntp.monitor camera3
>OK (0.003026)





More information about the questions mailing list