[armedslack] An ntp hint

Phil Ehrens phil at slug.org
Wed Sep 2 16:50:06 UTC 2009


You probably don't want to run ntpd on a plug, unless you
are using it as a time server, but you DO want the time to
be correct, because it's a hazard to run a networked computer
with time skew, so you should put this in /etc/cron.daily:

~~~ snip ~~~
#!/bin/sh 
#
# Name: ntpsynch.sh
#
# Purpose: Keep the clock sane!
#
# Comment:
#
#    ntpdate is called twice because it
#    takes two calls to get it "dead-on".
#
/usr/sbin/ntpdate -b time.caltech.edu 2>&1 >/dev/null
sleep 2
/usr/sbin/ntpdate -b time.caltech.edu 2>&1 >/dev/null
~~ snip ~~~

It should of course also be run as early as possible at
reboot. Slackware calls rc.ntpd from rc.M, so you should
copy this script to /etc/rc.d/rc.ntpd as well if you
want to be sure your clock is sane at boot.

Phil




More information about the ARMedslack mailing list