[NTLUG:Discuss] Clock issue
MadHat
madhat at unspecific.com
Mon Jun 4 10:56:52 CDT 2001
At 05:00 PM 6/1/2001 -0500, Richard Geoffrion wrote:
>Schedule this command in cron
>
><command>
>/usr/sbin/ntpdate time.nist.gov 1> /dev/null 2> /dev/null
></command>
>
>to sync your time with the clock in bolder. Of course you'll have to verify
>the presense and location of your ntpdate command.
most versions ntpdate will only work if the offset is less than 128
miliseconds, otherwise it slews the time, which could take hours to
correct, you have to add -b to force it to update the time right then using
the settimeofday() system call. I use
/usr/sbin/ntpdate -bs time.xxxx.yyy
in my /etc/rc.local or /etc/rc.d/rc.local or /etc/rc.conf.local depending
on the distro and OS.
the -s is use syslog rather than STDERR, as I like to know when there are
problems, rather than just throwing them away... no redirects of output
necessary.
then have xntpd running to sync on a regular basis after the time is
initially set...
See
http://www.eecis.udel.edu/~ntp/
for details on NTP
More specifically for ntpdate...
http://www.eecis.udel.edu/~ntp/ntp_spool/html/ntpdate.htm
>Visit http://www.boulder.nist.gov/timefreq/service/its.htm to read up about
>NTP and find alternate time sources.
>
>
>----- Original Message -----
>From: "Chris Cox" <cjcox at acm.org>
>To: <discuss at ntlug.org>
>Sent: Friday, June 01, 2001 4:42 PM
>Subject: Re: [NTLUG:Discuss] Clock issue
>
>
> > I noticed under certain loads, the clock doesn't keep up.
> > Before everyone cries.... Solaris will do the same thing.
> > What I did was use NTP (xntp...whatever) to sync to a
> > reliable time source. Alternatively, you can grab and
> > sync from the hw clock... but that's probably not as nice
> > in a production environment.... but good enough for
> > home use.
> >
> > "George E. Lass" wrote:
> > >
> > > Can't help you with why, but you could fix the difference by running
> > > hwclock --utc --hctosys
> > > periodically as a cron job.
> > > If your hwclock is not using utc then omit --utc from the above command.
> > >
> > > If you are connected to the 'net full time you might also want to check
> > > out
> > > xntp.
> > >
> > > George
> > >
> > > WILLIAM PEARSON wrote:
> > > >
> > > > Hello,
> > > >
> > > > I'm running Red Hat 6.0 and my system clock is running about 15-20
>minutes
> > > > slow. When I go into the system CMOS the time is correct. What could
>be
> > > > causing this and how can I fix it? It has been this way since I
>installed
> > > > the OS.
> > > >
> > > > William Pearson
> > > >
> > > > _______________________________________________
> > > > http://www.ntlug.org/mailman/listinfo/discuss
> > > _______________________________________________
> > > http://www.ntlug.org/mailman/listinfo/discuss
> > _______________________________________________
> > http://www.ntlug.org/mailman/listinfo/discuss
> >
>
>_______________________________________________
>http://www.ntlug.org/mailman/listinfo/discuss
--
MadHat at unspecific.com
"Focus on the packet. It's better that way."
-tb
More information about the Discuss
mailing list