Port-xen archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Updating Xen's time-of-day clock



On Thu, May 04, 2006 at 07:29:08PM -0400, Jed Davis wrote:
> Attached is a patch to have the NetBSD dom0 periodically reset Xen's
> time-of-day clock; there's a sysctl to change the interval or disable
> the functionality entirely.  More eyes/opinions are desired (also
> about the sysctl name; "machdep.xen_timepush_ticks" is a little
> unwieldy).
> 
> Currently, we set Xen's time only on settimeofday(2); so, if the time
> is being disciplined by ntpd or by periodic runs of ntpdate that use
> adjtime(2), then Xen's clock will continue to drift.  This is bad
> because domU use that value to set their clocks on boot (and resume),
> and Linux in particular defaults to tying its local clock to the
> hypervisor's.
> 
> The Linux dom0 does this every 60 seconds (which, for usual values of
> drift, will keep the step size under a tick); out of probably
> excessive paranoia that that might line up with a cron job or
> something and cause strange non-reproducible problems, I used a less
> round number.

Looks good to me. 

-- 
Manuel Bouyer <bouyer%antioche.eu.org@localhost>
     NetBSD: 26 ans d'experience feront toujours la difference
--



Home | Main Index | Thread Index | Old Index