Description of problem:
An image was created in virt-manager with the default format set to qcow2 for new images. After trying to use that image in openstack I found that the image is actually a qcow3 image. I am unable to convert from qcow3 to qcow2 because qemu-img doesn't recognize qcow3.
Version-Release number of selected component (if applicable):
Everytime a new image is created when qcow2 is set as default, it creates a qcow2 image.
Steps to Reproduce:
1. Set virt-manager prefs so new images are qcow2
2. Create and install a new VM from ISO
3. Run file against the .qcow2 image that is created, and it will show that it is qcow3
A qcow3 image is created:
# file rhel6_sat6.qcow2
rhel6_sat6.qcow2: QEMU QCOW Image (v3), 8589934592 bytes
I except that this would create a qcow2 image, or at the very least that I could convert it with the latest version of qemu-img
I can convert qcow2v3 to qcow2v2 with latest qemu-img
# rpm -q qemu-img
# qemu-img convert -f qcow2 /var/lib/libvirt/images/qcow2v3.img -O qcow2 -o compat=0.10 /var/lib/libvirt/images/qcow2v2.img
# file /var/lib/libvirt/images/qcow2v2.img
/var/lib/libvirt/images/qcow2v2.img: QEMU QCOW Image (v2), 1073741824 bytes
Should qemu-img-1.6.2-6.fc20.x86_64 can also do that.
Yes, virt-manager/virt-install on Fedora 20 by default create images that won't run on RHEL6. It's a pain, but we need to extra features to get acceptable snapshot performance.
See Shanzhi's suggestion for conversion:
> # qemu-img convert -f qcow2 /var/lib/libvirt/images/qcow2v3.img -O qcow2 -o
> compat=0.10 /var/lib/libvirt/images/qcow2v2.img
Indeed that should work on F20 qemu 1.6 as well. However it will discard any internal qcow2 snapshots, so beware.
(qemu-img etc. don't have an explicit qcow3 version, it's just qcow2 + compat options. The 'QCOW Image (v3)' comes from the qcow2 header, I wish it didn't say that though since it's misleading).
Also see this mail for more details: