Dual Booting on Separate M.2 Drives Win10 and Arch

So I first installed Windows 10 on one M.2 Drive. Got everything setup and working fine.

Then I opened the laptop and removed the M.2 SSD and put in a fresh M.2 Drive and installed Arch Linux. Got everything setup the way I wanted it to be.

I then use my Windows 10 (only for Native Instruments–Kontakt is too good!), and now it’s time to replace the drives and use Arch again.

So I boot up and get Default Boot Device Missing or Boot Failed.
I load up with the live USB and my partitions are all there for my Arch install.
Secure Boot is disabled.

I’ve seen a lot of topics on dual booting on the same drive or using an expansion card. But wasn’t finding anything on opening the laptop and changing them out. It’s easy to do, so I figured this would be best for not having to worry about grub issues and windows destroying my glorious Arch install. Besides, those Kontakt libraries will fill up my hard drive soon enough.

Anyone have any idea? Thanks in advance.

You’ll have to reset your boot priority to First or Last in the BIOS settings then select the drive. This list should be persistent so both drives should be there.

I find the Framework BIOS behaves differently than most here - if it boots and the first drive in the list is not connected, it puts up this error. Other BIOSes just move on and only error like this if every device in the list is not found.

It’d be easier to install both on one SSD and use GRUB to pick which OS to boot. Here’s the rough outline of how I set up my computer:

  • boot a Lubuntu image on a MicroSD card (Ventoy makes this easy and is cross-platform)
  • use Lubuntu to install Gentoo on the SSD
  • reboot into Gentoo; make sure os-prober is available along with GRUB, and make the EFI partition large enough to hold the contents of /boot (mine’s 256 MB and less than half full)
  • boot a Win1x image, possibly from the same MicroSD card as above
  • install Win1x
  • reboot; you’ll now get Win1x, so we need to fix the boot order
  • boot Lubuntu from MicroSD again; chroot into Gentoo
  • reinstall GRUB with grub-install --target=x86_64-efi --efi-directory=/boot
  • rewrite grub.cfg so that it’ll find Win1x: grub-mkconfig | sed "s/GNU\///g;s/Windows Boot Manager/Windows 11/g" >/boot/grub/grub.cfg (or change “Windows 11” to “Windows 10” if appropriate)
  • reboot; GRUB should now come up with boot options for Linux and Windows, and will default to Linux

Another option is running Windows on a virtual machine in Arch - it’s not all that hard to run QEMU VMs under Arch and you get nearly native performance out of them. That way you don’t have to swap drives or even reboot. That’s what I do for running Microsoft Office or if I need a Windows-based tool.

You can even install quickemu through the AUR that automates the whole process from downloading the right copy of Windows to setting up the VM.

Kontakt looks like it has pretty light system requirements, so it would probably run just fine in a VM.

Ok, I have a sorta work-around:

I mounted my boot partition, arch-chroot into it, then installed refind.
I rebooted and it gave me a prompt to boot into my Arch linux.

to test it out, I reinstalled the windows drive, started up, shutdown, then reinstalled the Arch drive.

back to same issue…
So, I just mount my boot partition, arch-chroot into, then run refind-install and it writes back to NVRAM.

I guess windows overwrites the NVRAM on boot and Arch Linux doesn’t

The easiest way to handle switching drives without having to rely on the NVRAM settings being correct is to install your bootloaders to the “fallback location”. It is an architecture-specific directory on the ESP that stores a default bootloader. There’s one you can use for Linux documented here (this page is packed with useful information :))

In short: If you have a bootloader at EFI\BOOT\BOOTX64.EFI in your EFI system partition, the system will boot it even if there are no boot entries in NVRAM. Windows installs its bootloader to the fallback location in addition to the correct vendor-specific location, EFI\Microsoft.

1 Like