You are not logged in.

#1 2020-10-07 00:56:50

rcorre
Member
Registered: 2015-11-27
Posts: 62

[SOLVED] New EFI boot entry disappears after reboot

TLDR: if an ESP on an NVMe drive isn't showing as a boot option, make sure your motherboard supports it!

---

I'm trying to install Arch on a newly-installed NVME drive, using my existing EFI Arch install to boostrap.
Both the old and new installs use systemd-boot. Both "root" partitions are LVM on LUKS.
I don't have Windows installed, which seems to be the usual culprit for disappearing EFI entries.

/dev/sda1 -- old EFI partition
/dev/sda2 -- old root
/dev/nvme0n1p1 -- new EFI partition
/dev/nvme0n1p1 -- new root

I'm bootstrapping the new installation as described at https://wiki.archlinux.org/index.php/In … Arch_Linux.
When I reboot, the newly created EFI boot entry (created by bootctl install) disappears.

EFI entry 0x0007 appears after I run `bootctl install` in the arch-chroot.
When I reboot, the firmware doesn't show any entries for the nvme drive.
When I boot back into my old install, EFI entry 0x0007 is gone again.

There also appears to be some junk in there from old installs I should probably clean out (grub/windows/gummiboot are not used).

System:
     Firmware: UEFI 2.31 (American Megatrends 4.653)
  Secure Boot: disabled
   Setup Mode: setup
 Boot into FW: supported

Current Boot Loader:
      Product: systemd-boot 241.7-2-arch
     Features: ✓ Boot counting
               ✓ Menu timeout control
               ✓ One-shot menu timeout control
               ✓ Default entry control
               ✓ One-shot entry control
               ✗ Support for XBOOTLDR partition
               ✗ Support for passing random seed to OS
               ✓ Boot loader sets ESP partition information
          ESP: /dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f
         File: └─/EFI/SYSTEMD/SYSTEMD-BOOTX64.EFI

Random Seed:
 Passed to OS: no
 System Token: set
       Exists: yes

Available Boot Loaders on ESP:
          ESP: /boot (/dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f)
         File: └─/EFI/systemd/systemd-bootx64.efi (systemd-boot 241.7-2-arch)
         File: └─/EFI/BOOT/BOOTX64.EFI (systemd-boot 241.7-2-arch)

Boot Loaders Listed in EFI Variables:
        Title: ARCH
           ID: 0x0001
       Status: active, boot-order
    Partition: /dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f
         File: └─/EFI/ARCH/GRUBX64.EFI

        Title: Linux Boot Manager
           ID: 0x0000
       Status: active, boot-order
    Partition: /dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f
         File: └─/EFI/GUMMIBOOT/GUMMIBOOTX64.EFI

        Title: UEFI OS
           ID: 0x0003
       Status: active, boot-order
    Partition: /dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f
         File: └─/EFI/BOOT/BOOTX64.EFI

        Title: Linux Boot Manager
           ID: 0x0004
       Status: active, boot-order
    Partition: /dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f
         File: └─/EFI/SYSTEMD/SYSTEMD-BOOTX64.EFI

        Title: Windows Boot Manager
           ID: 0x0002
       Status: inactive, boot-order
    Partition: /dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f
         File: └─/EFI/MICROSOFT/BOOT/BOOTMGFW.EFI

        Title: Linux Boot Manager
           ID: 0x0007
       Status: active, boot-order
    Partition: /dev/disk/by-partuuid/ee013ffa-9d4d-4342-91d2-152948198cb2
         File: └─/EFI/systemd/systemd-bootx64.efi

Boot Loader Entries:
        $BOOT: /boot (/dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f)

Default Boot Loader Entry:
        title: Arch Linux Fallback
           id: fallback-arch.conf
       source: /boot/loader/entries/fallback-arch.conf
        linux: /vmlinuz-linux
       initrd: /initramfs-linux-fallback.img
      options: cryptdevice=UUID=4ec3f07e-d8e6-4d70-a788-cd2478492514:cryptlvm root=/dev/MyVolGroup/root
Disk /dev/nvme0n1: 465.76 GiB, 500107862016 bytes, 976773168 sectors
Disk model: WDC WDS500G2B0C-00PXH0                  
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: E9D9F588-498C-994B-BA22-1E7E9D9E6F89

Device           Start       End   Sectors   Size Type
/dev/nvme0n1p1    2048   1050623   1048576   512M EFI System
/dev/nvme0n1p2 1050624 976773134 975722511 465.3G Linux filesystem


Disk /dev/sda: 232.89 GiB, 250059350016 bytes, 488397168 sectors
Disk model: Samsung SSD 850 
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 82094296-4DB5-45C6-B0C6-BA33A6D05D0A

Device       Start       End   Sectors   Size Type
/dev/sda1     2048   1050623   1048576   512M EFI System
/dev/sda2  1050624 488397134 487346511 232.4G Linux LVM

Any advice is appreciated. Thanks!

Last edited by rcorre (2020-10-07 13:00:31)

Offline

#2 2020-10-07 01:20:13

rcorre
Member
Registered: 2015-11-27
Posts: 62

Re: [SOLVED] New EFI boot entry disappears after reboot

Running bootctl-status from the chroot says:

System:
     Firmware: UEFI 2.31 (American Megatrends 4.653)
  Secure Boot: disabled
   Setup Mode: setup
 Boot into FW: supported

Current Boot Loader:
      Product: systemd-boot 241.7-2-arch
     Features: ✓ Boot counting
               ✓ Menu timeout control
               ✓ One-shot menu timeout control
               ✓ Default entry control
               ✓ One-shot entry control
               ✗ Support for XBOOTLDR partition
               ✗ Support for passing random seed to OS
               ✓ Boot loader sets ESP partition information
WARNING: The boot loader reports different ESP UUID then detected!
          ESP: /dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f
         File: └─/EFI/SYSTEMD/SYSTEMD-BOOTX64.EFI

Random Seed:
 Passed to OS: no
 System Token: set
       Exists: yes

Available Boot Loaders on ESP:
          ESP: /boot (/dev/disk/by-partuuid/ee013ffa-9d4d-4342-91d2-152948198cb2)
         File: └─/EFI/systemd/systemd-bootx64.efi (systemd-boot 246.6-1-arch)
         File: └─/EFI/BOOT/BOOTX64.EFI (systemd-boot 246.6-1-arch)

Boot Loaders Listed in EFI Variables:
        Title: Linux Boot Manager
           ID: 0x0000
       Status: active, boot-order
    Partition: /dev/disk/by-partuuid/ee013ffa-9d4d-4342-91d2-152948198cb2
         File: └─/EFI/systemd/systemd-bootx64.efi

        Title: Linux Boot Manager
           ID: 0x0004
       Status: active, boot-order
    Partition: /dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f
         File: └─/EFI/SYSTEMD/SYSTEMD-BOOTX64.EFI

        Title: UEFI OS
           ID: 0x0003
       Status: active, boot-order
    Partition: /dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f
         File: └─/EFI/BOOT/BOOTX64.EFI

        Title: Windows Boot Manager
           ID: 0x0007
       Status: active, boot-order
    Partition: /dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f
         File: └─/EFI/MICROSOFT/BOOT/BOOTMGFW.EFI
WARNING: The boot loader reports different ESP UUID then detected!
          ESP: /dev/disk/by-partuuid/eb4fc46c-8ad8-496a-b7e4-4cc48003de2f

Could be my issue. That PARTUUID is /dev/sda1, not /dev/nvme0n1p1.
What I want to do is start using an ESP partition on nvme0n1p1 instead of sda1.

Offline

#3 2020-10-07 02:23:24

rcorre
Member
Registered: 2015-11-27
Posts: 62

Re: [SOLVED] New EFI boot entry disappears after reboot

I rebooted with sda physically disconnected just to see if I could force it to use to ESP in the nvme0n1p1. No boot entries appeared. After reconnecting sda and rebooting, it appears that all the boot entries on sda were removed and replaced by a single "Windows Boot Manager" entry that just says "Your PC/Device needs to be repaired". I'm not even sure I can get to an EFI shell at this point.

In retrospect I probably should have just kept /dev/sda1 as the ESP, but for future reference: is it possible to change the ESP on a device that already has one?

Offline

#4 2020-10-07 10:20:00

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 10,831

Re: [SOLVED] New EFI boot entry disappears after reboot

This entirely depends on your firmware so information on your mainboard would be nice.

Normal (... spec-abiding) firmwares should support different ESPs on different devices, seems like yours is pretty dead set on only supporting one.

Offline

#5 2020-10-07 11:29:53

rcorre
Member
Registered: 2015-11-27
Posts: 62

Re: [SOLVED] New EFI boot entry disappears after reboot

Offline

#6 2020-10-07 12:12:42

rcorre
Member
Registered: 2015-11-27
Posts: 62

Re: [SOLVED] New EFI boot entry disappears after reboot

I noticed that the firmware interface lists my HDD as a boot option, even though it has no EFI/boot partition (just one big encrypted ext4 partition).
However the M.2 SSD doesn't show up at all.

I stumbled on A Gigabyte Forum Post suggesting "It is since F6 for NVMe support.". I'm on BIOS version F5.
I'm guessing that's it.

Offline

#7 2020-10-07 12:59:04

rcorre
Member
Registered: 2015-11-27
Posts: 62

Re: [SOLVED] New EFI boot entry disappears after reboot

I ran bootctl-install again using the ESP on the old SATA SSD, and it seems happy now.
I don't want ESP on my M.2 badly enough to risk flashing the motherboard firmware, so I'll make my peace with this.
Cheers!

Offline

Board footer

Powered by FluxBB