time/date sync and hwclock
Bill Day
bill
Mon May 17 11:29:56 PDT 2004
This is morning message from CRON:
Subject: Cron <root at linuxbox> rdate -p -s clock-1.cs.cmu.edu && hwclock
--systohc
[clock-1.cs.cmu.edu] Tue Apr 16 04:59:42 2002
/bin/sh: hwclock: command not found
I have checked that hwclock does work. I am running the command (at one
point a script) as root to sync the system time with the closest best ping
time timeserver and for the life of me I cannot get the script to finish
successfully and update the hardware clock as well.
Below is the script I was using before just the command line, neither seem to
work. Any Ideas?
The one that mimics the SxS:
if rdate -s clock-1.cs.cmu.edu; then
hwclock --systohc
fi
The one someone else told me to try:
rdate -s clock-1.cs.cmu.edu && hwclock --systohc
As you can see running it in a term gives me no errors:
[root at linuxbox /root]# hwclock
Tue Apr 16 08:19:23 2002 -0.903347 seconds
[root at linuxbox /root]# hwclock --systohc
[root at linuxbox /root]#
I canset my time to some ungoddly months days and hours
off and as soon as I run the script my system time is correct but my hwclock,
from cron gives command not found.
TIA,
--
Bill Day
Linux for Windows Addicts:
A Twelve Step Program for Habitual Windows Users.
ISBN: 0072130814
Get it cause Ol' Billy Gates don't want you too!
7:30am up 20 days, 12:09, 3 users, load average: 1.02, 0.69, 0.60
More information about the Linux-users
mailing list