Re: System time

Discussion in 'Computer Information' started by Paul, Oct 13, 2011.

  1. Paul

    Paul Guest

    Edwin Sineath wrote:
    > My computer has recently started not being able to keep system time. I'm
    > running LinuxMint 10.0
    > I set it this morning and right now it is at 3:19 when the actual time
    > right now is 3:23
    > Any ideas what is going on?

    When a computer is "sleeping", time is kept by the RTC (real time clock).
    The RTC is a similar design to a digital watch. It is a part of the
    Southbridge chip, and is an emulation of a very old chip from Motorola.
    A 32KHz crystal (just like in a digital watch) is the signal source
    in that case. And if the computer is unplugged, or switched off via
    the switch on the power supply, the RTC runs from the CMOS coin cell
    (sits in a socket on the motherboard).

    So, if the computer "doesn't keep good time" while the machine is sleeping
    or powered off or the like, you're looking at the behaviors of the RTC
    or the battery.


    When the computer is running, the computer switches to the "software clock".
    There are two reasons for using a software clock. First, it has a lot
    more digits on the output, and can measure in quantities like microseconds.
    The second reason, is the readout phase is faster. The hardware interface
    on the RTC is very slow to read, and if you were "timing" things, like
    in a stopwatch situation, some amount of error in the reading would result
    from the very poor readout interface.

    As a result, the operating system maintains a "software clock", which is
    incremented every time a "clock tick interrupt" is serviced. The clock
    tick interrupt is traceable to a different quartz crystal on the motherboard.
    That quartz crystal probably isn't any better or worst than the 32KHz one.

    A quartz crystal has an initial tolerance, and it also has temperature
    induced drift. In a properly designed digital clock, the designer attempts
    to do "temperature compensation". I don't see any evidence of that caring,
    when it comes to computer design. The end result is, the clock does not
    keep accurate time (neither the RTC nor the clock tick interrupt thing,
    keeps good time).

    To fix that, people synchronize the time on their computer, to an external
    NTP (network time protocol) server on the Internet. I use for
    example. The computer can go out at regular intervals, and get a reading
    of the much more accurate clocks available on the Internet. Using the NTP
    protocol and software, it's possible to work out a "drift factor" for the
    clock. And, at regular intervals, make corrections to the drift. If your
    clock was losing a second per day, with regularity, things like NTP can
    just about perfectly compensate for it.

    What they can't fix, is random drift factors. If your room gets extremely
    hot or extremely cold, perhaps the NTP thing would be off a bit, as the
    clock would be drifting at a different rate than the "estimate" from
    the computed drift factor.

    One defect that causes very large errors, is when the computer suffers
    from "spurious interrupts". This is a hardware failure, where some piece
    of hardware generates an interrupt signal, when there is no actual
    piece of hardware that needs service. If thousands of those arrive per
    second, or if even a few, high priority ones of that nature happen, it
    can affect the ability to do good software timekeeping. Generally, the
    clock will always drift in one direction when that happens (probably
    slower than real time, as clock tick interrupts are getting lost).

    An example was a problem with the Nforce2 chipset, where even with
    frequent NTP updates, the clock was off by large percentage factors.
    That was an interrupt problem of some sort, which apparently was
    only evident if the chip was operated at a non-canonical clock speed
    on its input.


    Your first step would be, to use the Date & Time control panel, and
    check whether you're synchronizing to an NTP server. Under the
    "Internet Time" tab right now, my machine is set to automatically
    update from "". But I have other machines that are
    set to , which is a pool of hundreds of servers
    which use a random DNS scheme so that NTP requests can be distributed
    over a large number of servers. That makes a bit more
    resilient to loading. ( )

    The interval between syncs on the Windows feature, can be changed,
    but it requires changing a value in the registry some where. If
    you needs better features than Windows provides, there are third-party
    NTP software packages, that do things like keep good logs of drift
    factor, and some of the info from a log like that, may help you
    determine whether the statistics of the drift, exceed the
    normal range of quartz crystal related issues (which are in the
    parts per million).

    There are occasions, where the NTP server you're syncing to, is
    actually mis-configured. And then the time can be off by rather
    large amounts. Anyone running a public NTP server, is supposed
    to check it once in a while and make sure it works.

    You can use this for a rough check. Attempt a manual sync, using
    Date & Time or other means, then while you've got the clock on
    your screen (with second hand showing), compare to this web site.

    Paul, Oct 13, 2011
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. longshotjohn7

    Re: Same error message time and time again.

    longshotjohn7, Sep 3, 2003, in forum: Computer Support
    Boomer :)
    Sep 3, 2003
  2. Forgotten Boy

    Audio just *quits" from time to time

    Forgotten Boy, Sep 4, 2003, in forum: Computer Support
    W. Wallace
    Sep 5, 2003
  3. Replies:
  4. suresh_rtp
    Apr 22, 2009
  5. suresh_rtp
    Jul 7, 2009