I am really new to this, and I tried to install archlinux (from the official Arch ISO: here) onto a 128GB USB 3.1 Samsung key (this one) using the x86 emulator QEMU on MacOS.

I finished installing everything:

  1. Boot up QEMU with the USB key accessible
  2. Write to USB key as partition table format GPT
  3. Make 261MiB ESP using parted (VFAT, FAT32)
  4. Make a blank partition with a ext4 filesystem (100% of the remaining space)
  5. Pacstrap Arch on the second partition
  6. Configure Arch (date/time mainly, fstab stuff)
  7. Install GRUB2 onto the EFI partition
  8. Bless the EFI partition

I tried to reboot into Arch from my Mac and also from a Windows computer (I don't know what version, sorry), but it never appeared as a bootable partition (I just saw "Macintosh HD" as the only option, I mean).

As far as I can tell, the problem is that I am missing all of my efivars. Supposedly, their location is meant to be at /sys/firmware/efi but (after arch-chroot /mnt-ing) ls /sys/firmware gives me only acpi devicetree dmi memmap qemu_fw_cfg.

Here is a list of all of the commands that I did in order, up until I started trying to solve my efivars crisis: here.

Since then, I tried installing rEFInd (efibootmgr --create --disk /dev/vda --part 1 --loader /EFI/BOOT/bootx64.efi --label "rEFINd Boot Manager" --verbose), which installed properly, but didn't seem to help much. I tried modprobe efivars and modeprobe efivar per this recommendation, and it told me "FATAL: Module efivar not found in directory /lib/modules/5.1.5-arch1-2-ARCH."

Here is the profile of my Mac, if it helps:


It's not clear to me if you are trying to boot the USB stick directly on the Mac or using the QEMU emulator. I didn't see anything about QEMU in your numbered list.

If your intention is to run Arch Linux on to of QEMU, and you want to do it using UEFI firmware, then you will have to use UEFI firmware with QEMU. Because QEMU emulates a whole machine, including the firmware, you can't use the native firmware (be it UEFI or legacy BIOS). OVMF is a port of the Tianocore UEFI firmware implementation to QEMU. You will have to specify the OVMF firmware file to QEMU/KVM when booting up the virtual machine.

| improve this answer | |
  • Hi Mr. Myréen, I used QEMU to bootstrap Arch onto the USB key. The desire is to do away with QEMU once everything is said and done. I want to be able to commandeer any computer (within reason) and reboot into Arch from my USB key. I will try using OVMF, that sounds like it could be the problem. I am assuming I will need to re-bootstrap/pacstrap after learning how to use this OVMF? – Confused ArchMonero Dev Jun 14 '19 at 21:14
  • It was not clear to me what role QEMU had. If I understand correctly (this time!), you don't need OVMF, because that is only needed for QEMU. Once you boot directly (without QEMU) from the prepared USB stick, you are using the native UEFI firmware. Your problem seems to be that the native firmware on your host does not see the USB stick, or does not like it for some reason, which makes it unavailable for selection when you boot the computer. One possible reason could be that secure boot is enabled which means your unsigned USB stick cannot be booted. – Johan Myréen Jun 15 '19 at 6:23
  • By the way, you should be able to boot the ISO directly if you write the ISO file to the USB stick. I realize this is not the desired end result, but booting from the USB stick is much easier to test this way. If you can't get the installation media to boot using USB, then you need to troubleshoot that first, because it is essentially an Arch installation made for installing Arch. Once you get the installation USB stick to boot, you can use that to install your own Arch on another USB stick; there is no need for QEMU. – Johan Myréen Jun 15 '19 at 6:32
  • So if I understand correctly, the lack of efivars is not actually a problem, and I should change my secure boot settings. And that would explain why it failed to appear as bootable in both Windows and MacOS (on two different computers). – Confused ArchMonero Dev Jun 15 '19 at 20:08
  • Well, secure boot is just one possible reason why the USB stick doesn't show up. On a PC, at least, you will have to select the boot order in the firmware setup so that the external drive has priority over the internal hard disk. I'm not familiar with Macs. – Johan Myréen Jun 15 '19 at 20:45

I changed my secure boot settings (honestly I just added a password to allow all bootable drives to appear).

If you also had this problem, reboot into the recovery partition (command-R when the apple appears on boot-up), and go to Utilities > Secure Boot Settings or something like that — the top one anyway.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.