I should have made the same settings when I bought the computer, but I forgot how to do it, so make a note.
** This article is just a memo. Those who refer to it are at their own risk. ** **
When I rebooted the machine after updating the BIOS, Windows started up instead of Arch Linux.
Use efibootmgr to set the boot order. The sudo
is omitted below, so add it as needed.
Here, the options of efibootmgr are explained using the command (below) typed in my environment as an example.
$ efibootmgr -c -d /dev/sda -p 1 -L "Arch Linux" -l "\EFI\boot\bootx64.efi"
See the Gentoo wiki for more information.
Create a new boot entry.
Enter the name of the disk where Linux is installed. You can check it with lsblk
etc.
In my environment, Windows is installed in / dev / nvme0n1
and Arch Linux is installed in / dev / sda
, so I chose -d / dev / sda
.
You can check it with fdisk -l
, parted -l
, etc.
It was 1 in my environment, so I chose -p 1
.
Give it a nice name.
Enter the path of the efi file specified when creating the configuration file for the boot loader such as grub.
However, ** use \
instead of /
** for the path.
In my environment, the efi file was in / boot / EFI / boot / bootx64.efi
, so change/
in the path under / boot
to \
and -l" \ EFI I made it \ boot \ bootx64.efi "
.
In my environment, when I restarted my computer, the boot order set by ʻefibootmgr` was reset. However, the boot entry itself was created correctly, so I was able to change the boot order from the BIOS settings.
If the boot entry itself cannot be found, the above-mentioned setting of the value of -l
may be incorrect. Check if the boot entry was created correctly with ʻefibootmgr -v`.
If you find something wrong, please let us know in the comments. See you soon.