Re: gettimeofday() goes backwards on FreeBSD 4.9

Поиск
Список
Период
Сортировка
От Kurt Roeckx
Тема Re: gettimeofday() goes backwards on FreeBSD 4.9
Дата
Msg-id 20031129131443.GA1067@ping.be
обсуждение исходный текст
Ответ на Re: gettimeofday() goes backwards on FreeBSD 4.9  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Fri, Nov 28, 2003 at 08:22:30PM -0500, Tom Lane wrote:
> 
> One variable I didn't think to ask about is whether you are running
> NTP.  In my experience an ntp daemon that has achieved lock will never
> step the clock back by even 1 usec (it's supposed to use much more
> subtle methods than that to manage the clock ;-)) but maybe under
> unstable conditions such things could happen.  The machines I have
> tested here all run NTP.

ntpd will slew the clock in case the difference is small enough.
Which means it will tell the kernel to slow down time a little.

In case the offset is too large (0.128 seconds) it will tell the
kernel to step the clock.

ntpd also has an option to "always slew".  But it's broken on
atleast Linux 2.4.

Note that the kernel uses values from different places to
calculate what the current time is, and they're not all running
on the same frequency.  I wouldn't worry about a 1 us step back.


Kurt



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Gavin Sherry
Дата:
Сообщение: Re: gettimeofday() goes backwards on FreeBSD 4.9
Следующее
От: Tom Lane
Дата:
Сообщение: Re: cvs head configure broken for --with-krb5 on RH9