clock problem

Martin Dieringer martin.dieringer at gmx.de
Tue May 8 13:35:51 UTC 2007


On Tue, 8 May 2007, Oliver Fromme wrote:

> Martin Dieringer wrote:
> > My clock is now _15 minutes_ late, after about 1 day with powerd
> > running.
> > ntpd is running also.
> > Can nobody tell where the problem is here?
>
> Are you sure that your /etc/ntp.conf ist correct?


# cat /etc/ntp.conf

server time.fu-berlin.de iburst maxpoll 9
driftfile /var/db/ntp.drift
logfile /var/log/ntpd
#


# cat /var/db/ntp.drift
500.000
#


> Are there any messages from ntpd in /var/log/messages?
> What's the output from "ntpq -p"?

# ntpq -p
No association ID's returned
#

> Make sure that you have these two lines in /etc/rc.conf:
>
> ntpd_enable="YES"
> ntpd_sync_on_start="YES"

how can I sync on start if I have to first dialup?
I have ntpd_flags="-g" - the same?

and how will the clock run when not connected to the internet?
it should at least be somehow in a sensible range

> The second one is important -- it passes the -g option to
> ntpd.  Without that option, ntpd refuses to perform an
> initial correction if the clock offset is too large.
>
> If there are still problems, please show us the contents
> of your /etc/ntp.conf file.


now this is the machine with 2 minutes offset after 30hours uptime
(the other one has ntpd killed at signal 15 - some version problem I
think)
But 2 minutes is also too much

/var/log/ntpd:
  8 May 05:14:14 ntpd[585]: synchronized to 130.133.1.10, stratum=2
  8 May 05:28:22 ntpd[585]: time reset +1.574431 s
  8 May 05:29:35 ntpd[585]: synchronized to 130.133.1.10, stratum=1
  8 May 05:35:00 ntpd[585]: no servers reachable
  8 May 05:43:30 ntpd[585]: synchronized to 130.133.1.10, stratum=2
  8 May 05:52:04 ntpd[585]: no servers reachable
  8 May 06:34:47 ntpd[585]: synchronized to 130.133.1.10, stratum=1
  8 May 06:43:29 ntpd[585]: time reset +9.086484 s
  8 May 06:43:29 ntpd[585]: kernel time sync enabled 6001
  8 May 06:44:42 ntpd[585]: synchronized to 130.133.1.10, stratum=1
  8 May 06:44:42 ntpd[585]: kernel time sync enabled 2001
  8 May 06:44:45 ntpd[585]: time reset +0.948614 s
  8 May 06:45:58 ntpd[585]: synchronized to 130.133.1.10, stratum=1
  8 May 06:53:31 ntpd[585]: no servers reachable
  8 May 06:55:40 ntpd[585]: synchronized to 130.133.1.10, stratum=1
  8 May 06:57:50 ntpd[585]: no servers reachable
  8 May 07:57:35 ntpd[585]: synchronized to 130.133.1.10, stratum=2
  8 May 07:57:52 ntpd[585]: time reset +17.498739 s
  8 May 07:57:52 ntpd[585]: kernel time sync enabled 6001
  8 May 07:59:06 ntpd[585]: synchronized to 130.133.1.10, stratum=2
  8 May 07:59:06 ntpd[585]: kernel time sync enabled 2001
  8 May 07:59:09 ntpd[585]: time reset +0.201341 s
  8 May 08:00:20 ntpd[585]: synchronized to 130.133.1.10, stratum=2
  8 May 08:18:42 ntpd[585]: no servers reachable
  8 May 08:19:47 ntpd[585]: synchronized to 130.133.1.10, stratum=1
  8 May 08:23:01 ntpd[585]: time reset +1.131953 s
  8 May 08:24:15 ntpd[585]: synchronized to 130.133.1.10, stratum=1
  8 May 08:43:43 ntpd[585]: no servers reachable
  8 May 08:45:53 ntpd[585]: synchronized to 130.133.1.10, stratum=1
  8 May 08:45:56 ntpd[585]: time reset +2.680132 s
  8 May 08:47:05 ntpd[585]: synchronized to 130.133.1.10, stratum=1
  8 May 08:56:55 ntpd[585]: no servers reachable
  8 May 09:01:10 ntpd[585]: synchronized to 130.133.1.10, stratum=1
  8 May 09:05:28 ntpd[585]: no servers reachable




I can ping the server ok and internet was working at that time.
I have to redialup every 24h which normally works fine.


m.



More information about the freebsd-stable mailing list