Hi Everyone,
We have a use case where we need to mount two bootable disks to one vm. We specified the boot order so that it should always boot from the first disk. However, we found that sometimes the VM doesn't use the disk that is specified to boot. The command to bring up the VM is the following
qemu-system-x86_64 -m 10240 -boot strict=on \
-drive file=disk1.img,if=none,id=disk1 \
-device virtio-blk-pci,drive=disk1,bootindex=1 \
-drive file=disk2.img,if=none,id=disk2 \
-device virtio-blk-pci,drive=disk2,bootindex=2 \
-smp 8,cores=4, -nographic
We create the two disks with different sizes, and tell which disk the VM boots from using the lsblk command after the VM boots up. We use qemu version 7.2.
Anyone had a similar issue? Any idea on why and how we can fix this? Appreciate any help.
Thanks!
Zang