[fedora-virt] Problem when migrating qcow2 image from F20 to CentOS6

Cole Robinson crobinso at redhat.com
Mon Apr 14 11:54:49 UTC 2014

On 04/14/2014 06:52 AM, Kevin Wolf wrote:
> Am 14.04.2014 um 12:33 hat Pavel Lisý geschrieben:
>> Hello
>> I've made virtual guest on Fedora 20 (x86_64) within qcow2 image file
>> but after migration to CentOS 6.5 I've got this error:
>> qemu-kvm: -drive file=/var/lib/libvirt/images/questfile.qcow2,if=none,id=drive-virtio-disk0,format=qcow2: 'drive-virtio-disk0' uses a qcow2 feature which is not supported by this qemu version: QCOW version 3
>> similar error I've got for qemu-img:
>> # qemu-img info /var/lib/libvirt/images/questfile.qcow2
>> 'image' uses a qcow2 feature which is not supported by this qemu version: QCOW version 3
>> On F20 it returns:
>> # qemu-img info /var/lib/libvirt/images/questfile.qcow2
>> image: /var/lib/libvirt/images/rhel6.qcow2
>> file format: qcow2
>> virtual size: 32G (34359738368 bytes)
>> disk size: 4.7G
>> cluster_size: 65536
>> Have I missed something? 
>> Is it qcow2 on Fedora different from CentOS6? Is there any possibility
>> (on Fedora 20) to convert it to backward compatible format?
> qemu versions starting with 1.1 can use new qcow2 features which require
> an incompatible on-disk format. Between version 1.1 and 1.6, they needed
> to be specified explicitly during image creation, like this:
>     qemu-img create -f qcow2 -o compat=1.1 test.qcow2 8G
> Starting with qemu 1.7, compat=1.1 became the default, so that newly
> created images can't be read by older qemu versions by default. If you
> need to read them in older version, you now need to be explicit about
> using the old format:
>     qemu-img create -f qcow2 -o compat=0.10 test.qcow2 8G
> With the same release, qemu 1.7, a new qemu-img subcommand was
> introduced that allows converting between both versions, so you can
> downgrade your existing v3 image to the format known by RHEL 6 like
> this:
>     qemu-img amend -f qcow2 -o compat=0.10 test.qcow2
> However, it looked to me as if F20 still had qemu 1.6, so you shouldn't
> be seeing any of this, and your qemu-img may not have the 'amend'
> subcommand. Maybe one of the package maintainers can comment on any
> patches that F20 has on top of 1.6?

virt-manager in f20 uses compat=1.1 by default for new qcow2 images.
Unfortunately we didn't add any UI to change that setting, so you'll have to
create the qcow2 images by hand behind virt-manager's back.

The other option is grab a newer qemu from fedora-virt-preview so you can use
the qemu-img amend command:


- Cole

More information about the virt mailing list