Hide Forgot
Description of problem: Create qcow2 image, and then start this image with raw format as data disk of windows guest, then check this qcow2 image, find it become raw format using qemu-img info. Version-Release number of selected component (if applicable): qemu-kvm-0.12.1.2-2.147.el6.x86_64 How reproducible: 100% Steps to Reproduce: 1.create qcow2 image # qemu-img create -f qcow2 data.img 2G # qemu-img info data.img image: data.img file format: qcow2 virtual size: 2.0G (2147483648 bytes) disk size: 136K cluster_size: 65536 2. start windows guest with this qcow2 image with format=raw, -drive file=/home/data.img,if=none,id=drive-ide0-0-1,format=raw,cache=none -device virtio-blk-pci,drive=drive-ide0-0-1,id=ide0-0-1 3.login windows guest, and go to Disk Management, click on OK on pop up initialize disk windows. 4. check this image info again # qemu-img info data.img image: data.img file format: raw virtual size: 256K (262144 bytes) disk size: 136K Actual results: After start this qcow2 image in windows guest with format=raw, it become raw format. Expected results: It should keep qcow2 format. Additional info: Try this issue on RHEL guest, qcow2 format has no change.
That's works as designed. Otherwise it is a security hole.