qemu-img convert blocks other tasks
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
qemu-kvm (Ubuntu) |
Expired
|
Low
|
Unassigned |
Bug Description
Binary package hint: qemu-kvm
Steps to reproduce:
- Use qemu-img convert to convert an image. e.g. a large (40GB) raw file to a compressed qcow2 image
- Watch the load rise
- kernel messages will be like "INFO: task blocked for more than 120 seconds". (Also see below)
In some cases this will bring down the server. When running libvirt too, all virtual servers will timeout/crash.
Using ionice to renice qemu-img convert does not really prevent the issue.
kvm D 0000000000000000 0 9632 1 0x00000000
ffff8801a4269ca8 0000000000000086 0000000000015bc0 0000000000015bc0
ffff8802004fdf38 ffff8801a4269fd8 0000000000015bc0 ffff8802004fdb80
0000000000015bc0 ffff8801a4269fd8 0000000000015bc0 ffff8802004fdf38
Call Trace:
[<ffffffff8155
[<ffffffff8155
[<ffffffff810f
[<ffffffff811d
[<ffffffff8114
[<ffffffff8108
[<ffffffff8125
[<ffffffff8114
[<ffffffff8114
[<ffffffff8101
kdmflush D 0000000000000002 0 396 2 0x00000000
ffff88022eeb3d10 0000000000000046 0000000000015bc0 0000000000015bc0
ffff88022f489a98 ffff88022eeb3fd8 0000000000015bc0 ffff88022f4896e0
0000000000015bc0 ffff88022eeb3fd8 0000000000015bc0 ffff88022f489a98
ProblemType: Bug
DistroRelease: Ubuntu 10.04
Package: qemu-kvm 0.12.3+
ProcVersionSign
Uname: Linux 2.6.32-28-server x86_64
Architecture: amd64
Date: Thu Feb 3 12:34:13 2011
KvmCmdLine:
UID PID PPID C SZ RSS PSR STIME TTY TIME CMD
root 1809 1 0 188145 517408 3 Jan31 ? 00:21:36 /usr/bin/kvm -S -M pc-0.11 -enable-kvm -m 512 -smp 1 -name jessica -uuid 76a39821-
root 1909 1 0 248235 625280 3 Jan31 ? 00:21:14 /usr/bin/kvm -S -M pc-0.11 -enable-kvm -m 768 -smp 1 -name gurney -uuid 7a21a182-
root 27120 1 0 193095 552120 0 Jan31 ? 00:27:52 /usr/bin/kvm -S -M pc-0.11 -cpu qemu32 -enable-kvm -m 512 -smp 1 -name kolab -uuid 79b2a347-
ProcCmdLine: BOOT_IMAGE=
ProcEnviron:
PATH=(custom, user)
LANG=C
SHELL=/bin/bash
SourcePackage: qemu-kvm
dmi.bios.date: 02/23/2010
dmi.bios.vendor: Intel Corp.
dmi.bios.version: CBQ4510H.
dmi.board.
dmi.board.name: DQ45CB
dmi.board.vendor: Intel Corporation
dmi.board.version: AAE30148-301
dmi.chassis.type: 3
dmi.modalias: dmi:bvnIntelCor
Thanks for taking the time to report this bug and helping to make Ubuntu better.
For my own test on a natty server, I started with a 30G qcow2 disk with a lucid install on it. It had about 1G allocated. Conversion from qcow2 to raw took probably less than 10 seconds. Conversion back to qcow took a lot longer (perhaps a minute). So for a full 40G allocated drive I certainly would expect it to be slow.
However you certainly do seem to have a real problem there. In your CurrentDmesg, I see
[257894.409748] Buffer I/O error on device dm-9, logical block 0
[257894.409786] Buffer I/O error on device dm-9, logical block 0
This could indicate a real problem, or just a device which you've since removed (i.e. usb thumb drive). Could you look under /sys/block/dm-9 for more information?
Can you look for relevant info in /var/log/syslog from this event and paste them here?
Finally, could you re-test with the qemu-kvm package from the server-edgers's archive (see https:/ /launchpad. net/~ubuntu- server- edgers/ +archive/ server- edgers- qemu-kvm)?