lkml.org 
[lkml]   [2001]   [Nov]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: PROBLEM: Linux updates RTC secretly when clock synchronizes
    Riley,

    > server 127.127.1.0 # local clock
    > fudge 127.127.1.0 stratum 10

    'attempt to configure invalid address 127.127.1.0'; guess
    ntpd (as opposed to xntpd) doesn't support it.

    >> ... you are assuming that the RTC doesn't get adjusted first (to
    >> match the system clock)!
    >
    > If it does, what adjusts it?

    I got confused by the kernel /reading/ the CMOS clock,
    and the symptoms the original reporter suggested (see
    subject line). My symptoms came from non-APM driven
    suspend (hence high time offset, no clock/hwclock
    invocation) and writing back system clock to cmos clock
    on shutdown, AND ntp not adjusting if the date difference
    is greater than some small value AND ntpdate not being
    able to get to any time server including the CMOS clock
    when it was run; sigh...

    >>> 3. AFAICT, if xntpd writes to the RTC, then it has achieved true
    >>> synchronisation to a reference clock other than the RTC.
    >
    >> I thought the original poster was claiming that the /kernel/
    >> wrote to the RTC, which would explain the behaviour I'm seeing.
    >
    > The kernel itself never writes to the RTC, and that is one of Linus's
    > decisions with which I am in 100% agreeance (and one thing I hate about
    > Windows). In fact, the kernel itself also doesn't read from the RTC
    > either, but leaves that to userspace.

    The kernel does read from the rtc to support /dev/rtc, and in
    the apm code. AIUI that's why the kernel needs to know
    via config whether your RTC is in UTC (else that could
    be done in userspace too). You are probably correct that
    it doesn't write to it.

    > please advise what you find.

    Summary:

    1. ntpd (as opposed to xntpd) doesn't seem to support the rtc,
    as a clock source, at least not in the same way.

    2. suspending your laptop in a manner other than using apm
    doesn't do good things to the RTC when you later shut
    the machine down, with standard scripts.

    3. Check your ntpdate on init is doing what you think it's
    doing.

    --
    Alex Bligh
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 13:12    [W:0.056 / U:61.848 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site