1

My setup:

  • 1 hdd with Windows 10 installed
  • 1 ssd with Archlinux using systemd-boot installed
  • Motherboard: MSI X470 Gaming Pro

I first installed Arch, then Windows 10 and the dual boot worked like a charm, but after a BIOS-update, my Motherboard keeps automatically booting to Windows without going though systemd-boot first.

When checking the boot order in the bios, my ssd is still first but it now says Windows Boot Manager instead of UEFI OS (for Linux).

I can verify that the Linux drive still has all of my stuff on it and seems to be untouched.

contents of /boot/loader/

Can someone please explain to me why this happened?


In case someone is wondering how I solved it:

I booted from a USB-stick and mounted my ssd directories and moved the Microsoft directory from /boot/EFI/ to somewhere else.

Afterwards the bios label for my ssd correctly said UEFI OS again and booted to systemd-boot again (which obviously didn't show the Windows option anymore).

Finally I moved the Microsoft directory back to /boot/EFI/ and everything works again.

My question still is why it happened in the first place and how it can be avoided during future bios upgrades.

2

2 Answers 2

1

UEFI has it's own boot manager. This boot manager uses variables in NVRAM to locate and execute a bootloader and your BIOS uses these variables to list boot options in the boot menu. It's very likely that your BIOS Update interfered with your NVRAM and caused the problem.

6
  • Ok, thanks I think I get it now, I was/am just confused/surprised that the Windows Boot-loader seems to be preferred by the motherboard for some reason. Commented Mar 27, 2022 at 13:17
  • 1
    I think that's because Windows installs its bootloader in the default file path (usually used for removable media) to facilitate recovery if the NVRAM is corrupted. You can and should replace Windows Boot Manager with gummiboot as the default, but beware, it requires editing of NVRAM variables (which can be easily done using efibootmgr). Source: UEFI Booting
    – SeetheMoar
    Commented Mar 27, 2022 at 13:32
  • 1
    Gummiboot is dead, of course, because it was spun into systemd in 2015, It is a big change to use SystemD boot now from grub, but can be done if really desired. And it is not really a replacement for Windows boot loader.
    – oldfred
    Commented Mar 27, 2022 at 13:38
  • 1
    @oldfred Oh I apologize, I thought the questioner was using gummiboot (systemd-boot) because I was browsing another question with the same problem but with gummiboot. To fruiter: I meant that you should replace Windows's bootloader with the bootloader that you use
    – SeetheMoar
    Commented Mar 27, 2022 at 13:42
  • 1
    No, all good I figured you meant systemd-boot (which I use) by gummiboot. I'm going to try your tip out, once I have a bit of time. Thanks again^^ Commented Mar 27, 2022 at 13:59
1

I think you've perhaps misunderstood something important where your say you BIOS has "mislabeled my drive". The drive isn't the entry point... you can have many boot entries against the same drive with different labels.

So in context this is not about an incorrect boot entry, but the addition of a boot entry and the removal of the one you wanted.

SeetheMoar's answer points out that the NVRAM may have been wiped (likely). It's also pretty likely that the BIOS will check for Microsoft Windows first only searching other directories later. Microsoft still has enough dominance in the market for this to happen commonly enough.


On most BIOS there is a way you can manually add new entries on the boot screen. The path you would use is likely to be something like:

 /EFI/arch/grubx64.efi

If you are using Arch linux.


Otherwise, if you can boot into Linux then the tool efibootmgr will let you read, write and reorder boot entries.


Likewise under windows you can use bcdedit as described here

1
  • Yes that describes/clears my initial misunderstanding up pretty well thank You. Since I am using systemd-boot with the standard way (following the wiki) of installing Arch the correct efi file path is: /boot/EFI/systemd/systemd-bootx64.efi Commented Apr 13, 2022 at 22:38

You must log in to answer this question.

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