The included patch makes /etc/init.d/ntpd check for a /etc/ntp/tickadj.conf file and if found sets tick to this value. Also saves the current tick value on stop. This is very handy for those people who have to adjust their tick values via tickadj when their system is inaccurate due to overclocking or bunk hw clock. Reproducible: Always Steps to Reproduce: 1. 2. 3. --- ntpd 2003-07-01 12:19:46.000000000 -0500 +++ /shared/ntpd-tickadj 2003-07-06 17:26:12.000000000 -0500 @@ -20,6 +20,10 @@ start() { checkconfig || return $? + if [ -f /etc/ntp/tickadj.conf ] ; then + /usr/bin/tickadj `cat /etc/ntp/tickadj.conf` + fi + if [ -n "${NTPDATE_CMD}" ] ; then ebegin "Initializing clock via ${NTPDATE_CMD}" ${NTPDATE_CMD} ${NTPDATE_OPTS} > /dev/null @@ -35,6 +39,7 @@ } stop() { + /usr/bin/tickadj | sed -e "s/tick\ =\ //g" >/etc/ntp/tickadj.conf ebegin "Stopping ntpd" start-stop-daemon --stop --quiet --pidfile /var/run/ntpd.pid eend $? "Failed to stop ntpd"
Created attachment 14253 [details, diff] patch to /etc/init.d/ntpd
I seem to have set it as a P2 when it's not, my apologies.
doesnt the drift file take care of this ?
welp, as far as i know, the drift file serves this purpose