You are not logged in.

#1 2011-03-08 16:29:29

pedro_sland
Member
Registered: 2010-05-21
Posts: 15

[solved] ntp sync for more than 24 hours

What I am trying to do:
I discovered that my server was out by about 8 minutes the other day. I have run ntpd -qg but I'd like a solution to stop this happening in the future.

I've read:
https://wiki.archlinux.org/index.php/Time
https://wiki.archlinux.org/index.php/Ne … e_Protocol

I'm confused. Surely the ntp daemon does exactly the same as this:

Running "ntpd -qg" as a cron event is to be completely avoided, unless you are perfectly aware of how your running applications would react to instantaneous system time changes.

Thanks for your help.

Last edited by pedro_sland (2011-03-08 17:31:14)

Offline

#2 2011-03-08 16:30:59

Inxsible
Forum Fellow
From: Chicago
Registered: 2008-06-09
Posts: 9,183

Re: [solved] ntp sync for more than 24 hours

Did you read about the time skew on the first link that you have posted?


Forum Rules

There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !

Offline

#3 2011-03-08 16:42:47

pedro_sland
Member
Registered: 2010-05-21
Posts: 15

Re: [solved] ntp sync for more than 24 hours

I did but I re-read it. I think I've got the relevant bit.

The Linux kernel keeps track of the system clock by counting timer interrupts. ... NTP will adjust the interrupt frequency and the number of ticks per second to decrease system clock drift.

So ntpd -qg jumps to the right time and ntp running as a daemon will speed up the clock to make it right? If that is the case, I understand why running that as a cron job is not recommended.

To satisfy my curiosity, why does the kernel skip interrupts?

Offline

#4 2011-03-08 17:05:46

skunktrader
Member
From: Brisbane, Australia
Registered: 2010-02-14
Posts: 1,538

Re: [solved] ntp sync for more than 24 hours

pedro_sland wrote:

To satisfy my curiosity, why does the kernel skip interrupts?

Usually, because it is busy doing real work like performing disk IO and reading the network card and updating the screen and ...

Offline

Board footer

Powered by FluxBB