diff -ruN ntp.orig/ntp-client ntp/ntp-client --- ntp.orig/ntp-client 1969-12-31 19:00:00.000000000 -0500 +++ ntp/ntp-client 2010-02-25 21:55:23.557220716 -0500 @@ -0,0 +1,30 @@ +#!/bin/bash + +. /etc/rc.conf +. /etc/rc.d/functions +. /etc/conf.d/ntp-client.conf + +case "$1" in + start) + stat_busy "Starting NTP Client" + /usr/bin/ntpd -q $NTP_CLIENT_OPTION > /dev/null 2>&1 + if [ $? -gt 0 ]; then + stat_fail + else + add_daemon ntp-client + stat_done + fi + ;; + stop) + stat_busy "Stopping NTP Client" + rm_daemon ntp-client + stat_done + ;; + restart) + $0 stop + sleep 1 + $0 start + ;; + *) + echo "usage: $0 {start|stop|restart}" +esac diff -ruN ntp.orig/ntp-client.conf ntp/ntp-client.conf --- ntp.orig/ntp-client.conf 2010-02-25 21:51:17.667245238 -0500 +++ ntp/ntp-client.conf 2010-02-25 21:53:19.867233018 -0500 @@ -1,11 +1,5 @@ -# change this to a server closer to your location -NTP_CLIENT_SERVER="pool.ntp.org" - # client options -NTP_CLIENT_OPTION="-b -u" - -# timeout for the ntp-client -NTPCLIENT_TIMEOUT=10 +NTP_CLIENT_OPTION="-g" # arguments passed to ntpd when started NTPD_ARGS="-g" diff -ruN ntp.orig/ntpdate ntp/ntpdate --- ntp.orig/ntpdate 2010-02-25 21:51:17.667245238 -0500 +++ ntp/ntpdate 1969-12-31 19:00:00.000000000 -0500 @@ -1,30 +0,0 @@ -#!/bin/bash - -. /etc/rc.conf -. /etc/rc.d/functions -. /etc/conf.d/ntp-client.conf - -case "$1" in - start) - stat_busy "Starting NTP Client" - /usr/bin/ntpdate $NTP_CLIENT_OPTION -t $NTPCLIENT_TIMEOUT $NTP_CLIENT_SERVER > /dev/null 2>&1 - if [ $? -gt 0 ]; then - stat_fail - else - add_daemon ntpdate - stat_done - fi - ;; - stop) - stat_busy "Stopping NTP Client" - rm_daemon ntpdate - stat_done - ;; - restart) - $0 stop - sleep 1 - $0 start - ;; - *) - echo "usage: $0 {start|stop|restart}" -esac