Guillaume Rousse
2009-Feb-16 10:39 UTC
[Xen-devel] comprehensive documentation of clock-related options for HVM guests
Hello list. Despite using ntp, we''re facing heavy clock skews on our HVM guests, which happen to be almost all x86_64 linux. I''ve been browsing the list archive, I found reference to two different xen guest configuration options: - timer_mode - hpet However, I couldn''t find neither reference documentation, neither on their default values. According to this tread, the default for timer_mode was changed in some part of the source tree from 0 to 1: http://lists.xensource.com/archives/html/xen-devel/2008-10/msg00261.html But according to this one, there was a discussion for changing timer_mode from 0 to 2, and hpet from 0 to 1: http://lists.xensource.com/archives/html/xen-devel/2008-06/msg00095.html And according to XendConfig.py code (3.3.1), the default value for both of them is actually 0... This is a bit confusing :( -- BOFH excuse #243: The computer fleetly, mouse and all. _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Dan Magenheimer
2009-Feb-16 15:18 UTC
RE: [Xen-devel] comprehensive documentation of clock-related options for HVM guests
I agree it is confusing. There is no good default. Your best plan is to specify timer_mode=2 in the config file for hvm x86_64 linux guests. I think the defaults in XendConfig.py are to ensure that old saved guests don''t get confused by a different default.> -----Original Message----- > From: Guillaume Rousse [mailto:Guillaume.Rousse@inria.fr] > Sent: Monday, February 16, 2009 3:40 AM > To: xen-devel@lists.xensource.com > Subject: [Xen-devel] comprehensive documentation of clock-related > options for HVM guests > > > Hello list. > > Despite using ntp, we''re facing heavy clock skews on our HVM guests, > which happen to be almost all x86_64 linux. I''ve been > browsing the list > archive, I found reference to two different xen guest > configuration options: > - timer_mode > - hpet > > However, I couldn''t find neither reference documentation, neither on > their default values. > > According to this tread, the default for timer_mode was > changed in some > part of the source tree from 0 to 1: > http://lists.xensource.com/archives/html/xen-devel/2008-10/msg00261.html But according to this one, there was a discussion for changing timer_mode from 0 to 2, and hpet from 0 to 1: http://lists.xensource.com/archives/html/xen-devel/2008-06/msg00095.html And according to XendConfig.py code (3.3.1), the default value for both of them is actually 0... This is a bit confusing :( -- BOFH excuse #243: The computer fleetly, mouse and all. _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Keir Fraser
2009-Feb-16 15:24 UTC
Re: [Xen-devel] comprehensive documentation of clock-related options for HVM guests
It''s also worth pointing out that NTP synchronisation in dom0 does not affect HVM guest synchronisation at all. And in general that would be very hard to do in a way that isn''t fragile. The only solutions I can see here for absolute time synchronisation are a PV driver or daemon for time handling (which we do not currently have for any type of HVM guest) or perform NTP synchronisation in the guest itself (our time handling should be accurate enough for an ntp daemon to latch onto it). -- Keir On 16/02/2009 15:18, "Dan Magenheimer" <dan.magenheimer@oracle.com> wrote:> I agree it is confusing. There is no good default. Your > best plan is to specify timer_mode=2 in the config file > for hvm x86_64 linux guests. > > I think the defaults in XendConfig.py are to ensure that > old saved guests don''t get confused by a different default. > >> -----Original Message----- >> From: Guillaume Rousse [mailto:Guillaume.Rousse@inria.fr] >> Sent: Monday, February 16, 2009 3:40 AM >> To: xen-devel@lists.xensource.com >> Subject: [Xen-devel] comprehensive documentation of clock-related >> options for HVM guests >> >> >> Hello list. >> >> Despite using ntp, we''re facing heavy clock skews on our HVM guests, >> which happen to be almost all x86_64 linux. I''ve been >> browsing the list >> archive, I found reference to two different xen guest >> configuration options: >> - timer_mode >> - hpet >> >> However, I couldn''t find neither reference documentation, neither on >> their default values. >> >> According to this tread, the default for timer_mode was >> changed in some >> part of the source tree from 0 to 1: >> http://lists.xensource.com/archives/html/xen-devel/2008-10/msg > 00261.html > > But according to this one, there was a discussion for changing > timer_mode from 0 to 2, and hpet from 0 to 1: > http://lists.xensource.com/archives/html/xen-devel/2008-06/msg00095.html > > And according to XendConfig.py code (3.3.1), the default value for both > of them is actually 0... > > This is a bit confusing :(_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Guillaume Rousse
2009-Feb-17 08:38 UTC
Re: [Xen-devel] comprehensive documentation of clock-related options for HVM guests
Keir Fraser a écrit :> It''s also worth pointing out that NTP synchronisation in dom0 does not > affect HVM guest synchronisation at all. And in general that would be very > hard to do in a way that isn''t fragile. The only solutions I can see here > for absolute time synchronisation are a PV driver or daemon for time > handling (which we do not currently have for any type of HVM guest) or > perform NTP synchronisation in the guest itself (our time handling should be > accurate enough for an ntp daemon to latch onto it).That''s what (ntp sync in guests) we do, sorry if I wasn''t clear. I''ve tried timer_mode=1 yesterday, it seem to have reduced the deviation to an acceptable level for every host but one. I''ll try to switch to timer_mode=2 today. -- BOFH excuse #40: not enough memory, go get system upgrade _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Keir Fraser
2009-Feb-17 09:41 UTC
Re: [Xen-devel] comprehensive documentation of clock-related options for HVM guests
On 17/02/2009 08:38, "Guillaume Rousse" <Guillaume.Rousse@inria.fr> wrote:> Keir Fraser a écrit : >> It''s also worth pointing out that NTP synchronisation in dom0 does not >> affect HVM guest synchronisation at all. And in general that would be very >> hard to do in a way that isn''t fragile. The only solutions I can see here >> for absolute time synchronisation are a PV driver or daemon for time >> handling (which we do not currently have for any type of HVM guest) or >> perform NTP synchronisation in the guest itself (our time handling should be >> accurate enough for an ntp daemon to latch onto it). > That''s what (ntp sync in guests) we do, sorry if I wasn''t clear. I''ve > tried timer_mode=1 yesterday, it seem to have reduced the deviation to > an acceptable level for every host but one. I''ll try to switch to > timer_mode=2 today.Good idea. Timer_mode=0 is in general pretty bad. 1 and 2 seem to cover most guests okay. -- Keir _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel