4

I've got a Linux KVM guest that hangs after several weeks. Looking at the virt-manager window shows 100% CPU usage. virsh reboot guest doesn't take any effect, the guest needs to be forced off. On the guest I can see no indication of what went wrong. I've scanned /var/log/messages and just about any other log file that can might tell me something. After rebooting the system is stable for several weeks and then hangs again.

I've tried the following things:

  • Add clocksource=acpi_pm to the kernel boot options
  • Changing the disk bus from Virtio to IDE
  • Changing the NIC to e1000

All to no avail. Right now I'm at a point where I reboot the server on a weekly basis.

Are there any other ways to diagnose what is going wrong here? Or any other changes that might be made?

2
  • Try logging top -b -n output minutely, so after a hang, you can see what used all the CPU power. Jul 13, 2013 at 14:14
  • This was a good suggestion. Unfortunately, there was no excessive CPU usage. Aug 28, 2013 at 13:45

2 Answers 2

2

try to get something from qemu log from /var/log/libvirt/qemu/<domain-id>.log.

If your VM hangs, try to use guestfs to inspect VM disk file and check /var/log/messages and/or /var/log/dmesg to see what happens inside the VM.

3
  • This was a good suggestion. Unfortunately there was nothing in the logs. Aug 28, 2013 at 13:44
  • According to your solution, it seems that the virtual disk is corrupted. So you can inspect this virtual disk via command guestfish --ro -a /path/to/virtual-disk, then you can take a look at the logs from guest file system to see what happened.
    – shawnzhu
    Aug 29, 2013 at 0:33
  • Yes, that was what I tried. By using guestfish, the messages, dmesg, and other logs showed nothing wrong. Aug 29, 2013 at 13:41
0

I was unable to determine the cause of these crashes. I resolved this by reinstalling the guest in a new virtual disk. For the crashing VM, I had converted it from a VirtualBox image that an employee had created. I suspect that was the cause of the problem.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.