I'm getting this index=0 exists
error when I try to run qemu with this specific lines:
Command:
qemu-system-x86_64 `
-cpu "Penryn-v1" `
-boot order=c,once=d `
-m 4096 `
-smp 2,sockets=2,cores=2,threads=2,maxcpus=8 `
-drive file="F:\Maquinas Virtuais\VMs\Kali.img",media=disk `
-drive file="F:\Maquinas Virtuais\ISOs\kali-linux-2021.4a-installer-amd64.iso",media=cdrom
Output:
WARNING: Image format was not specified for 'F:\Maquinas Virtuais\VMs\Kali.img' and probing guessed raw.
Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted.
Specify the 'raw' format explicitly to remove the restrictions.
F:\qemu\qemu-system-x86_64.exe: ,media=disk: drive with bus=0, unit=0 (index=0) exists
PS F:\Maquinas Virtuais\VMs>
If I'd remove the part of the media=
, then QEMU starts but it's looks like it can't find the files ( the .img
and .iso
files do not load on QEMU)
Command:
qemu-system-x86_64 `
-cpu "Penryn-v1" `
-boot order=c,once=d `
-m 4096 `
-smp 2,sockets=2,cores=2,threads=2,maxcpus=8 `
-drive file="F:\Maquinas Virtuais\VMs\Kali.img" `
-drive file="F:\Maquinas Virtuais\ISOs\kali-linux-2021.4a-installer-amd64.iso"
I tried to explicit tell qemu the bus,unit and index
on the -drive
flag, but the error is the same everytime
I managed to start QEMU by removing the -drive
line and issuing the -hda
for the .img disk
and -cdrom
for the .iso cdrom
.
Command:
qemu-system-x86_64 `
-cpu "Penryn-v1" `
-boot order=c,once=d `
-m 4096 `
-smp 2,sockets=2,cores=2,threads=2,maxcpus=8 `
-hda "F:\Maquinas Virtuais\VMs\Kali.img" `
-cdrom "F:\Maquinas Virtuais\ISOs\kali-linux-2021.4a-installer-amd64.iso"
Anyone knows why QEMU issue the error that index=0 exists
when trying to run QEMU with the -drive
flag with the specific atribute of the media=
being passed? Even without the media=
, QEMU do not starts as intended, as it can't find the files to boot the cdrom or HD.