lkml.org 
[lkml]   [2001]   [Oct]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: PROBLEM: Linux updates RTC secretly when clock synchronizes
From
On Wed, Oct 31, 2001 at 02:05:38AM +0100, Kurt Roeckx wrote:
> On Wed, Oct 31, 2001 at 11:33:12AM +1100, Ian Maclaine-cross wrote:
> >
> > PROBLEM: Linux updates RTC secretly when clock synchronizes.
> >
> > When /usr/sbin/ntpd synchronizes the Linux kernel (or system) clock
> > using the Network Time Protocol the kernel time is accurate to a few
> > milliseconds. Linux then sets the Real Time (or Hardware or CMOS)
> > Clock to this time at approximately 11 minute intervals. Typical RTCs
> > drift less than 10 s/day so rebooting causes only millisecond errors.

[snip]

>
>
> This is all in the manpage, see man hwclock. If you use ntpd,
> you probably don't want hwclock to adjust, just set the time.
>
> Kurt
>

When the machine reboots from a power interruption Internet connection
may be unavailable (usual here). Ntpd can start synchronized to an RTC
but time is inaccurate because hwclock has not adjusted it. When
Internet connection reestablishes ntpd notices the time conflict and
terminates. Human intervention or cron lines can run ntpdate and then
restart ntpd. This results in time of low quality.

There are lots of high quality and cost hardware solutions. The
solution in my first post was a very small kernel patch to add an
11 minute update log so hwclock etc could adjust the time. Any
comments on my patch?


--
Regards,
Ian Maclaine-cross (iml@debian.org)
-
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:18    [W:0.111 / U:7.644 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site