Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 297432 - qemu-kvm 0.11.1 hangs on reboot/shutdown
Summary: qemu-kvm 0.11.1 hangs on reboot/shutdown
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo QEMU Project
URL: https://bugs.launchpad.net/qemu/+bug/...
Whiteboard:
Keywords:
Depends on: 297451
Blocks:
  Show dependency tree
 
Reported: 2009-12-18 15:19 UTC by Timothy Miller
Modified: 2010-04-02 17:42 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Timothy Miller 2009-12-18 15:19:53 UTC
I'm using qemu-kvm 0.11.1 on ~amd64.  I am running Windows XP as a guest OS.  I find that about half the time when I shut down or reboot the guest, the VM will hang, using 100% of one host CPU (about 85% user, 15% system).

I filed a bug report directly with qemu here:
https://bugs.launchpad.net/qemu/+bug/498035

The response I got was "Please try with 0.12.0-rc2."

I am therefore filing this bug report here to politely request that Gentoo devs grab a more recent version of qemu.

I can give you more of my system details, but I'm not sure what's important here.  I've googled for this, and I have found other reports of qemu hanging on shutdown.

Reproducible: Sometimes
Comment 1 Thomas Sachau gentoo-dev 2009-12-22 13:57:24 UTC
Please retest with 0.12.1.1 and report back. Also, please check, if you reboot during fullscreen mode or in window mode.
Comment 2 Timothy Miller 2009-12-22 14:52:03 UTC
I always use it in VNC mode.  I've tried rebooting a few times.  I haven't seen any trouble.  SiSoft SANDRA and qemu don't seem to get along well, so I tried running some tests in that, but it shut down just fine.
Comment 3 Timothy Miller 2009-12-24 02:01:05 UTC
This bug is definitely not fixed.  I'm using app-emulation/qemu-kvm-0.12.1.1, and it too will sometimes hang up on shutdown or reboot.
Comment 4 Timothy Miller 2009-12-24 02:16:06 UTC
I asked on IRC, but I'm not getting much help there trying to diagnose this.  Here's what I know:

- When Windows doesn't use ACPI to power off, you get a screen that tells you that you can power down now.  I'm not getting that screen.  It's still saying "Windows is shutting down..."
- The QEMU monitor responds, so it's not completely frozen up.  Something's going wrong inside the VM.
- It doesn't usually hang up.  This seems to happen mostly when I reboot after I install software or do something that requires heavy disk or network activity.  I understand that this bug has in the past been associated with the audio driver, but I can't tell if any audio happened, because I'm using VNC.
- I haven't done anything to prevent Windows from using ACPI.
Comment 5 Timothy Miller 2009-12-24 02:53:59 UTC
A QEMU dev told me to use the git version.  What are the chances we could get
an ebuild for the git version?  (A version 9999?)
Comment 6 kfm 2010-01-21 06:21:03 UTC
Timothy, would you please confirm as to whether the bug still exists in qemu-kvm-0.12.2? Also, if you have spoken to a developer could you perhaps ask them to narrow it down to a commit that fixes this particular bug?
Comment 7 Timothy Miller 2010-01-23 14:19:23 UTC
I'm running version 0.12.2.

I've tried a few things, and I don't get it to hang up on shutdown.  But like I say, it didn't always happen.  In fact, it never happens any more when I try intentionally to trigger it.  Only when I least expect it.  :)  So I'll let you know.

I do keep getting lots of these messages now, which I didn't get before.  

BUG: kvm_dirty_pages_log_enable_slot: invalid parameters
BUG: kvm_dirty_pages_log_disable_slot: invalid parameters
BUG: kvm_dirty_pages_log_enable_slot: invalid parameters
BUG: kvm_dirty_pages_log_disable_slot: invalid parameters
BUG: kvm_dirty_pages_log_enable_slot: invalid parameters
BUG: kvm_dirty_pages_log_disable_slot: invalid parameters
BUG: kvm_dirty_pages_log_enable_slot: invalid parameters
BUG: kvm_dirty_pages_log_disable_slot: invalid parameters
BUG: kvm_dirty_pages_log_enable_slot: invalid parameters
BUG: kvm_dirty_pages_log_disable_slot: invalid parameters
BUG: kvm_dirty_pages_log_enable_slot: invalid parameters
BUG: kvm_dirty_pages_log_disable_slot: invalid parameters


For reference, this is how I start the VM:

qemu-system-x86_64 -vga std -drive cache=writeback,index=0,media=disk,file=winxp.img -k en-us -m 2048 -smp 2 -vnc :3101 -usbdevice tablet -boot c -enable-kvm &
Comment 8 Doug Goldstein (RETIRED) gentoo-dev 2010-01-24 05:54:36 UTC
(In reply to comment #7)
> I'm running version 0.12.2.
> 
> I've tried a few things, and I don't get it to hang up on shutdown.  But like I
> say, it didn't always happen.  In fact, it never happens any more when I try
> intentionally to trigger it.  Only when I least expect it.  :)  So I'll let you
> know.
> 
> I do keep getting lots of these messages now, which I didn't get before.  
> 
> BUG: kvm_dirty_pages_log_enable_slot: invalid parameters
> BUG: kvm_dirty_pages_log_disable_slot: invalid parameters
> BUG: kvm_dirty_pages_log_enable_slot: invalid parameters
> BUG: kvm_dirty_pages_log_disable_slot: invalid parameters
> BUG: kvm_dirty_pages_log_enable_slot: invalid parameters
> BUG: kvm_dirty_pages_log_disable_slot: invalid parameters
> BUG: kvm_dirty_pages_log_enable_slot: invalid parameters
> BUG: kvm_dirty_pages_log_disable_slot: invalid parameters
> BUG: kvm_dirty_pages_log_enable_slot: invalid parameters
> BUG: kvm_dirty_pages_log_disable_slot: invalid parameters
> BUG: kvm_dirty_pages_log_enable_slot: invalid parameters
> BUG: kvm_dirty_pages_log_disable_slot: invalid parameters
> 
> 
> For reference, this is how I start the VM:
> 
> qemu-system-x86_64 -vga std -drive
> cache=writeback,index=0,media=disk,file=winxp.img -k en-us -m 2048 -smp 2 -vnc
> :3101 -usbdevice tablet -boot c -enable-kvm &
> 

Your kernel and kvm modules are out of sync somehow.

Comment 9 Timothy Miller 2010-01-24 16:00:57 UTC
My kvm modules are the ones that came with the kernel.  They're the same ones that I was using before I updated qemu-kvm.  

In fact, my up-time is 14 days.  I haven't even unloaded/reloaded any kernel modules in that time.  So unless I've experienced memory corruption due to cosmic particle strike (not too likely with the 70nm technology in the RAMs, but not out of the question for the cache in the 45nm tech CPU), I'm using the exact same modules I was using two weeks ago with an earlier version of qemu-kvm that didn't produce these errors.

So I supposed I could try rebooting, but seriously, that's grasping at straws.

BTW, this is what uname -a says:
Linux compute0 2.6.32-gentoo-r1 #1 SMP Mon Dec 28 11:37:04 EST 2009 x86_64 Intel(R) Core(TM)2 Quad CPU Q9450 @ 2.66GHz GenuineIntel GNU/Linux
Comment 10 Sergey 2010-02-05 07:35:46 UTC
I'm getting the same messages. It is irrelevant to modules. I have a solid kernel. It came up in userspace part 0.12.2. I think it's linked whith new feature of block migration. Maybe kernel part is too old for userspace? I have 2.6.31-gentoo-r6.
Comment 11 Thomas Sachau gentoo-dev 2010-04-02 17:42:13 UTC
The messages should go away with kernel-2.6.33.

I will close this as fixed for now, please reopen, if it still happens. Would also be nice to know a way to reproduce it, when it still happens.