[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: ntpdate, /etc/timezone et all.



Eric Richardson wrote:
> 
> Stan Brown wrote:
> >
> > I am trying to get my machine to have the harware clock set to UTC, and honor the
> > TZ environment variable for displaying the correct local time. I will use ntpdate
> > to keep the time in synch.
> >
> > Curently I have the correct timezone in /etc/timezone, and the correct offset from
> > the hardware clock is being applied, but I can't seem to get my script that runs
> > ntpdate to set the hardware clock to UTC. It persists in setting it to the local
> > time, so my displayed time, after applying the offset, is incorect.
> 
> There was a good post on this awhile ago but basically it said that for
> ntp to work, the hardware clock has to be very close to the correct
> time. Use hwclock to set the time close and then try the ntp.
>
apt-get install ntp and then entered the machines
clock.llnl.gov  tock.usno.navy.mil tick.usno.navy.mil
I tried to set up ntp and here is some of my syslog output.
 
Mar 20 11:07:06 maxwell ntpd[2183]: ntpd 4.0.99g Wed Apr  5 01:44:42 MDT
2000 (1)
Mar 20 11:07:06 maxwell ntpd[2183]: signal_no_reset: signal 13 had flags
4000000Mar 20 11:07:06 maxwell ntpd[2183]: precision = 11 usec
Mar 20 11:07:06 maxwell ntpd[2183]: kern_enable is 1
Mar 20 11:07:06 maxwell ntpd[2183]: using kernel phase-lock loop 0040
Mar 20 11:07:06 maxwell ntpd[2184]: signal_no_reset: signal 17 had flags
4000000Mar 20 
Mar 20 11:15:49 maxwell ntpd[2183]: time reset 54.095257 s
Mar 20 11:15:49 maxwell ntpd[2183]: kernel pll status change 41
Mar 20 11:15:49 maxwell ntpd[2183]: synchronisation lost

I don't seem to have ntpdate. Here is ntptime.

maxwell:/var/log# ntptime
ntp_gettime() returns code 0 (OK)
  time be622187.e40a4000  Tue, Mar 20 2001 11:35:51.890, (.890781),
  maximum error 224461 us, estimated error 28785 us.
ntp_adjtime() returns code 0 (OK)
  modes 0x0 (),
  offset 28128.000 us, frequency -5.412 ppm, interval 4 s,
  maximum error 224461 us, estimated error 28785 us,
  status 0x1 (PLL),
  time constant 2, precision 1.000 us, tolerance 512 ppm,
  pps frequency 0.000 ppm, stability 512.000 ppm, jitter 200.000 us,
  intervals 0, jitter exceeded 0, stability exceeded 0, errors 0.

I read file:/usr/share/doc/ntp/README.Debian and then I ran 
hwclock --systohc --utc

/etc/init.d/ntp restart

Now syslog looks okay but ntptime reports an error.

maxwell:/var/log# ntptime
ntp_gettime() returns code 5 (ERROR)

Thanks,
Eric :-)



Reply to: