Description of problem: SPM node: ovirt - 5.5-2.1.98 VDSM: vdsm-4.5-4 when creating a new pre-allocated virtual disk on FCP storage an error occurs on the VDSM level 1621f383-fa7a-475a-8ae8-c8feb54e0c5c::WARNING::2009-11-15 14:09:06,033::misc::97::irs::FAILED: <err> = 'qemu-img: Error while formatting\n'; <rc> = 1 1621f383-fa7a-475a-8ae8-c8feb54e0c5c::DEBUG::2009-11-15 14:09:06,034::vg::95::irs::(vg) fe3fc2d8-ba10-4836-a957-be3f0a5fc1ef: syncExecCmd obj 51760b89-3eff-4e83-8ec0-014726393630 cmd ['/usr/sbin/lv s', '-o', 'attr', '--noheadings', 'fe3fc2d8-ba10-4836-a957-be3f0a5fc1ef/51760b89-3eff-4e83-8ec0-014726393630'] ex False try False 1621f383-fa7a-475a-8ae8-c8feb54e0c5c::ERROR::2009-11-15 14:09:06,307::task::312::irs::(runCmd): Exception in <bound method Secure.run of <storage.spm.Secure instance at 0x2b1ed20cfe18>> - Error cr ating a new volume: (["Formatting '/rhev/data-center/26592a60-9726-42b3-9372-fd141e3e746f/fe3fc2d8-ba10-4836-a957-be3f0a5fc1ef/images/d58ad81f-5dcd-4d5d-91ca-4e2353fbe8d2/51760b89-3eff-4e83-8ec0-0 4726393630', fmt=raw, size=2097152 kB"],) Version-Release number of selected component (if applicable): How reproducible: Steps to Reproduce: 1. create a new VM from blank (on FC SD) 2. attach for this VM a new virtual disk (IDE/pre-allocated) 3. see that the disk is not created in the GUI 4. check out VDSM log Actual results: Expected results: Additional info:
There is a regression with qemu-img. For some reason, formatting with raw format always fails: [root@green-vdsa ~]# /usr/bin/qemu-img create -f raw /dev/fe3fc2d8-ba10-4836-a957-be3f0a5fc1ef/51760b89-3eff-4e83-8ec0-014726393630 1G Formatting '/dev/fe3fc2d8-ba10-4836-a957-be3f0a5fc1ef/51760b89-3eff-4e83-8ec0-014726393630', fmt=raw, size=1048576 kB qemu-img: Error while formatting [root@green-vdsa ~]# /usr/bin/qemu-img create -f host_device /dev/fe3fc2d8-ba10-4836-a957-be3f0a5fc1ef/51760b89-3eff-4e83-8ec0-014726393630 1G Formatting '/dev/fe3fc2d8-ba10-4836-a957-be3f0a5fc1ef/51760b89-3eff-4e83-8ec0-014726393630', fmt=host_device, size=1048576 kB
What is the kvm version? Do you know when it worked?
If it works with -f host_device, then it's a device and not a raw file. That it doesn't work any more with -f raw is a bug fix (errors during image creation were not always reported), not a regression. You need to correct your call.
I may be missing something but I think this doesn't work [root@dhcp-X reg]# rpm -qa kvm kvm-83-147.el5 [root@dhcp-X reg]# lvcreate -n test system --size 1g Logical volume "test" created [root@dhcp-X reg]# qemu-img create -f raw /dev/system/test 500M Formatting '/dev/system/test', fmt=raw, size=512000 kB qemu-img: Error while formatting
(In reply to comment #22) > I may be missing something but I think this doesn't work > > [root@dhcp-X reg]# rpm -qa kvm > kvm-83-147.el5 > [root@dhcp-X reg]# lvcreate -n test system --size 1g > Logical volume "test" created > [root@dhcp-X reg]# qemu-img create -f raw /dev/system/test 500M > Formatting '/dev/system/test', fmt=raw, size=512000 kB > qemu-img: Error while formatting I was indeed missing something (didn't update kvm-qemu-img). Seems to work now.
*** Bug 540883 has been marked as a duplicate of this bug. ***
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHSA-2010-0271.html