On Wed, Dec 2, 2009 at 5:55 PM, Mike Connors <[email protected]> wrote: > Denis Heidtmann wrote: >> This AM the log showed an offset of 0.366 seconds, so it looks like >> the hardware clock was reset. Is it possible that the hardware clock >> is reset (on shutdown) to the nearest second? That would account for >> the offsets bouncing around, but staying under 1 second. > Here's an excellent article on system clock, hardware clock, and NTP. > https://wiki.ubuntu.com/HardwareClock > > What I gleaned from it: > The OS stores(shutdown) and retrieves(bootup) system time from the hardware > clock. > At bootup after the system clock is set per the hw clock, it's going to query > an NTP > server via ntpdate for a more accurate time setting. > > Although the hw clock can keep time, it's not as accurate as any level of > stratum (1-4) clock. > It "free runs" w/o a reference source. So I would expect small stepping like > this to occur, > especially if you're only syncing the time once a day. > > * Interesting factoid: A GPS receiver can be used as a Stratum 1 clock source.
Data: ntpdate runs during boot and logs an offset of something from .3 to .9 seconds. A short time after boot runing ntpdate from the command line reports an offset of .00##--something close to zero. Shutdown and reboot shortly later, ntpdate runs during boot and logs an offset of something from .3 to .9 seconds. Repeat as desired. I take this to mean that 1) the hardware clock was not synchronized better than 1 second on shutdown, or 2) the hardware clock gets bumped during the shutdown/reboot cycle, or 3) the hardware clock is unstable in the extreme, or 4) the system clock gets set to the rtc to within 1 second on boot. 1) and 4) seem to me to be effectively the same thing. I vote for 4), because I find in the logs: Dec 2 17:58:46 R2D4 kernel: [ 3.906800] rtc_cmos 00:08: setting system clock to 2009-12-03 01:58:34 UTC (1259805514) If it were set more accurately than the nearest second why would it not show in the log? -Denis _______________________________________________ PLUG mailing list [email protected] http://lists.pdxlinux.org/mailman/listinfo/plug
