Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 84512 - ntpd does not correctly set clock on startup
Summary: ntpd does not correctly set clock on startup
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: High normal
Assignee: SpanKY
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-03-08 06:24 UTC by Marek Zachara
Modified: 2005-03-08 16:02 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Marek Zachara 2005-03-08 06:24:10 UTC
For some reason yet not unknown to me my system ends up being 1hr ahead of real time after each shutdown. I have set up ntpd in a hope to solve this issue. This however doesnt seem to work. 
I run ntpd with '-g' option to allow this 1hr adjustment on startup, but it doesnt' seem to work. Or rather it works partially - if i don't set the '-g' option, the ntpd quits with a 'sanity' orror logged (which to be expected). However with the '-g' option the ntpd happily runs with 360000ms offset... :) (instead of shifting it on startup). Here is my ntpd.conf:
NTPD_OPTS='-g'
restrict default noquery notrust nomodify
restrict 127.0.0.1
restrict 10.0.0.0 mask 255.255.255.0
restrict 192.168.192.1
server 10.0.0.250
server 192.168.192.1
fudge 127.127.1.0 stratum 10
server 127.127.1.0
driftfile /var/lib/ntp/ntp.drift
logfile /var/log/ntp.log

here is output of ntpq -p  just after /etc/init.d/ntpd start:
     remote           refid      st t when poll reach   delay   offset  jitter
==============================================================================
+10.0.0.250      192.168.192.1    3 u   11   64  177    0.140  -360066   0.932
*192.168.192.1   150.254.183.15   2 u    4   64  177    0.384  -360066   0.103
 127.127.1.0     73.78.73.84      5 l    7   64  177    0.000    0.000   0.001

Reproducible: Always
Steps to Reproduce:
1. setup ntpd (-g, servers)
2. set 1hr time difference (ahead of local time) on a machine (my machine is +1GMT)
3. run ntpd (/etc/init.d/ntpd start)
4. look at the ntpd status (ntpq -p)  :)
Actual Results:  
the output is as in Details section 

Expected Results:  
the offset to the time servers shall be close to zero (the are on a local 
network)
Comment 1 SpanKY gentoo-dev 2005-03-08 16:02:31 UTC
use ntp-date and/or file a bug upstream