![]() |
SlugOS.Ntpclient HistoryHide minor edits - Show changes to markup October 18, 2009, at 10:00 AM
by -- Added optional installation of killall package.
Added lines 9-10:
If not already installed, also install the April 07, 2009, at 07:23 PM
by --
Added lines 65-79:
Run clock adjustment. /etc/init.d/slugclock Check if log file was created (if not, you have some problems). ls -la /var/log/ntp.log If file was created, but is empty, possibly time difference is too big to be corrected by ntp. In such a case first use the manual time adjustment with time close to the correct one (substitute hh:mm with current hour/minutes - e.g., 14:25). date -s hh:mm April 07, 2009, at 06:53 PM
by -- issues seen during SlugOS 5.3 installation
Changed lines 20-21 from:
You can determine your normal operating runlevel that should be 3: to:
You may need to change priviledges on the file Changed line 22 from:
runlevel to:
chmod 0755 /opt/etc/init.d/slugclock Changed lines 25-26 from:
On the directory /etc/rc#.d where # is the runlevel (/etc/rc3.d normally), link the script to be executed once at boot time: to:
You can determine your normal operating runlevel that should be 3: Changed line 28 from:
ln -s /etc/init.d/slugclock S99slugclock to:
runlevel Changed lines 31-32 from:
Install the cron daemon: to:
You may need to copy above created file to /etc/init.d Changed line 33 from:
ipkg install cron to:
cp /opt/etc/init.d/slugclock /etc/init.d/slugclock Changed lines 36-37 from:
And make sure that the clock is syncronized at least once an hour by editing the crontab as the user root with the following command: to:
On the directory /etc/rc#.d where # is the runlevel (/etc/rc3.d normally), link the script to be executed once at boot time: Changed line 39 from:
crontab -e to:
ln -s /etc/init.d/slugclock S99slugclock Changed lines 42-43 from:
Add the following line and save. to:
Install the cron daemon: Changed line 45 from:
0 * * * * /etc/init.d/slugclock to:
ipkg install cron Added lines 48-64:
If ipkg complains that cron is already installed by busybox, force installation ipkg -force-overwrite install cron And make sure that the clock is syncronized at least once an hour by editing the crontab as the user root with the following command: crontab -e Add the following line and save. 0 * * * * /etc/init.d/slugclock August 31, 2008, at 05:58 PM
by --
Added line 50:
More information can be found here: FixTheClockUsingAdjtimexAndNtpclient August 31, 2008, at 05:56 PM
by -- Ntpclient howto
Added lines 1-49:
Install the software needed to be an ipkg install ntpclient ipkg install ntp-utils ipkg install ntp-tickadj Create the file
#!/bin/sh
if [ -n "`pidof ntpclient`" ]; then
/bin/killall ntpclient 2>/dev/null
fi
/sbin/adjtimex -t 10000
/sbin/ntpclient -s -h pool.ntp.org > /var/log/ntp.log
/sbin/hwclock --systohc --utc
You can determine your normal operating runlevel that should be 3: runlevel On the directory /etc/rc#.d where # is the runlevel (/etc/rc3.d normally), link the script to be executed once at boot time: ln -s /etc/init.d/slugclock S99slugclock Install the cron daemon: ipkg install cron And make sure that the clock is syncronized at least once an hour by editing the crontab as the user root with the following command: crontab -e Add the following line and save. 0 * * * * /etc/init.d/slugclock |