I installed Arch Linux into a KVM virtual machine using the Installation Guide. The installation was successful because after rebooting, I boot into my fresh installation. The problem is that after I shut down,I can no longer boot into my new system.enter image description here

This is my qemu start script. If I uncomment the iso file, I can boot back into the arch iso and chroot into the new install and everything looks fine as far as I can tell.

cp /usr/share/OVMF/OVMF_VARS.fd /tmp/my_vars_arch.fd

qemu-system-x86_64 \
-name $vmname,process=$vmname \
-machine type=q35,accel=kvm \
-cpu host,topoext \
-smp 12,sockets=1,cores=6,threads=2 \
-m 32G \
-vga qxl \
-spice port=5930,disable-ticketing=on \
-device vfio-pci,host=43:00.0,multifunction=on \
-device vfio-pci,host=43:00.1 \
-device vfio-pci,host=0b:00.3 \
-rtc clock=host,base=localtime \
-serial none \
-parallel none \
-drive if=pflash,format=raw,readonly,file=/usr/share/OVMF/OVMF_CODE.fd \
-drive if=pflash,format=raw,file=/tmp/my_vars_arch.fd \
-boot order=dc \
-drive file=/dev/NVME-TANK/ext4-zvol,format=raw,if=virtio \
#-drive file=/home/boss/ISOs/archlinux-2022.03.01-x86_64.iso,index=1,media=cdrom \
-nic bridge,br=br0,model=virtio-net-pci

Edit: after installing Arch via the guide, I installed efibootmgr and bootloader according to These instructions

The paths I have specified for OVMF firmware are fine in that they work for other VMs.

I am able to boot directly into the system again by following these instructions, but I am still not sure what I need to check or do to make this happen by default. I think I installed grub and created grub.cfg correctly by doing:

grub-install --target=x86_64-efi --bootloader-id=grub_uefi --recheck

and then

grub-mkconfig -o /boot/grub/grub.cfg

I re-ran the above two commands after chrooting into the system, looks ok right? os-prober isn't needed for uefi, is it?

What am I missing?

One other detail, not sure if it is relevant: If I comment out all my passthrough devices, I get a different screen:

And one more: I installed Manjaro using a minimal live iso, and the same thing happened! Rebooted into the new install, but after shutting down, booted to the uefi shell.

1 Answer 1


Verify that you have generated the fstab file.

Read the part about Initramfs, if needed adjust and regenerate.



This was the Problem, adding those flags to the ISO solved it. See comments.

  • Thanks, I should have mentioned that I did generate fstab and mkinitcpio -P ran without errors.
    – Stonecraft
    Mar 22, 2022 at 9:49
  • 1
    Could this be relevant? wiki.archlinux.org/title/…
    – Chaas
    Mar 22, 2022 at 10:16
  • Thanks, I had not seen that. Unfortunately adding -global ICH9-LPC.disable_s3=1 to my qemu command did not help.
    – Stonecraft
    Mar 22, 2022 at 12:23
  • 1
    Update: I tried again, but this time I used -global ICH9-LPC.disable_s3=1 for booting the install ISO (instead of adding it post-install). I now can boot into my installation from the VM after a full shutdown. Not sure why I had to have it there from the get-go, but thank you!!!
    – Stonecraft
    Mar 22, 2022 at 13:18
  • Actually it seems I spoke to soon. This worked with the Manjaro installer, but Arch is still having the same problem. I just assumed if it fixed in in MJ it would fix it in Arch too. Still leaving it marked as "answered" because it did work for Manjaro.
    – Stonecraft
    Mar 23, 2022 at 3:03

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .