GNOME Bugzilla – Bug 674035
gnome-boxes should set 'magic' clock parameters for kvm guests
Last modified: 2016-03-31 14:00:09 UTC
From https://bugzilla.redhat.com/show_bug.cgi?id=750773#c35 : "Daniel Berrange 2012-04-12 10:43:27 EDT It wouldn't surprise me if all the random hangs seen with Win7 and KVM are due to clock timing issues. Windows 7 is particularly sensitive to inaccurate interrupt delivery for PIT/RTC. To obtain stability mgmt apps should set the following config params when running KVM guests: <clock offset="utc"> (change 'utc' to 'localtime' for Windows) <timer name="rtc" tickpolicy="catchup"/> <timer name="pit" tickpolicy="delay"/> </clock> Although this is important for Windows, it doesn't harm other OS, so it is reasonable to set these for all. Unfortunately, AFAIK, none of virt-install, virt-manager or GNOME Boxes currently set this."
(this needs libvirt-glib work first)
Created attachment 215328 [details] [review] Set timer policies in libvirt configuration Windows 7 is quite sensitive to the libvirt timer configuration while other OSes don't care. Configuring the RTC timer to 'catchup' and the PIT timer to 'delay' seems to help with some freezes during Windows 7 boot that I'm seeing.
Have you looked at a backtrace of qemu when it freezes?
Nope, happened quite late yesterday, the symptoms were similar to https://bugzilla.redhat.com/show_bug.cgi?id=812313 I'll try to reproduce and get a backtrace.
Review of attachment 215328 [details] [review]: Looks good otherwise but please do test if this somehow breaks other OSs. ::: src/vm-configurator.vala @@ -36,2 +36,5 @@ else clock.set_offset (DomainClockOffset.UTC); + + DomainTimer timer = new DomainTimerRtc (); + timer.set_tick_policy(DomainTimerTickPolicy.CATCHUP); nitpick: "(" -> " (" @@ +41,3 @@ + clock.add_timer (timer); + timer = new DomainTimerPit (); + timer.set_tick_policy(DomainTimerTickPolicy.DELAY); same here
(In reply to comment #5) > Review of attachment 215328 [details] [review]: > > Looks good otherwise but please do test if this somehow breaks other OSs. The fedora installer works as usual
(In reply to comment #6) > (In reply to comment #5) > > Review of attachment 215328 [details] [review] [details]: > > > > Looks good otherwise but please do test if this somehow breaks other OSs. > > The fedora installer works as usual ACK then, assuming you corrected the nictpicks I pointed out.
Attachment 215328 [details] pushed as e27ec72 - Set timer policies in libvirt configuration