Open end2endzone opened 9 months ago
If I create a new VM and use the existing VHD test2_demo_foobar.qcow2
, then I get the same issue. My image contains a minimum installation of ubuntu-22.04.2-desktop-amd64.iso
.
Reproducible steps:
issue74
.Save as type
from default Hard disk file (*.img)
to QCOW2 disk image (*.qcow2)
.issue74.qcow2
.qcow2
selected).issue74
without any cdrom attached.
"C:/Program Files/qemu/qemu-system-x86_64w.exe" -m 8000 -smp 1 -k pci-ohci -hda "F:/test/issue74/issue74.qcow2" -net nic,model=e1000 -net user -boot c -device sb16
issue74
with a small linux based os image cdrom attached (I personnaly tested with ubuntu-22.04.2-desktop-amd64.iso
and openmediavault_7.0-20-amd64.iso
)
issue74
without any cdrom attached.
"C:/Program Files/qemu/qemu-system-x86_64w.exe" -m 8000 -smp 8 -k pci-ohci -drive format=raw,file="F:/test/issue74/issue74.qcow2" -net nic,model=e1000 -net user -boot c -device sb16
I also tried the following:
issue74
with gparted-live-1.2.0-1-amd64.iso
cdrom attached.
"C:/Program Files/qemu/qemu-system-x86_64w.exe" -m 8000 -smp 8 -k pci-ohci -hda "F:/test/issue74/issue74.qcow2" -net nic,model=e1000 -net user -cdrom "E:/iso_images/gparted-live-1.2.0-1-amd64.iso" -boot c -device sb16
issue74
without any cdrom attached.
-hda "F:/test/issue74/issue74.qcow2"
and qcow2 format is recognized by qemu.In other worlds, just formatting the VHD does not trigger EmuGUI to incorrectly use the disk image as RAW. There is something else that I do not understand.
I covered this in another issue. Just create a RAW format disk instead of a QCOW2 one. This will make the VM survive.
I'm am using qcow2 image format for my virtual hard disks.
When I start the emulation through EmuGUI, way that the image is passed to qemu varies in different ways:
-hda "F:/test/test2_demo_foobar.qcow2"
-drive file="F:/test/test2_demo_foobar.qcow2",if=ide,media=disk
(with an empty qcow2, if I force an IDE controller)-drive format=raw,file="F:/test/test2_demo_foobar.qcow2"
(once ubuntu is installed on the disk)Note that the 3rd option is bad because it identifies the qcow2 image as raw bytes. This prevents qemu from booting using the image after an installation of ubuntu. If I make an installation over this, I will corrupt the qcow2 image with raw bytes. In other words, I will essentially use my qcow2 file as if I would have named it
test2_demo_foobar.img
.I am still struggling to find the minimum reproducible steps to reproduce the issue. But I think it starts to go bad once I installed something on the VHD.
According to QEMU's documentation (here and here), raw and qcow2 are the preferred formats for virtual hard disk.
In the gui, when I edit the selected virtual machine, the virtual hard disk format is correctly identified as qcow2: