You are not logged in.

#1 2024-11-25 19:22:21

Franco_64
Member
From: Milano, Italy
Registered: 2021-11-20
Posts: 49

[SOLVED] efibootmgr doesn't show item in EFI bios

Hi,

I'm trying to install Arch in my new PC in parallel with Windows 11.

What I want to achieve is a "clean" installation of Arch on a Sata SSD internally connected, without a boot loader loaded on the nvme disk where I have Windows, so I want to use efibootmgr and do the operating system change via the EFI bios. The motherboard is a MSI Mag B 650 Tomahawk WIFI with its bios (which has a very stupid interface, IMHO).

No problem during disk partition etc until installing efibootmgr, which however does not "activate" in the EFI bios the entry to boot on Arch.

I try to rebuild the efibootmgr entry from my memory, because I write from Windows now:

efibootmgr --create --disk /dev/sdc --part 1 --label "Arch Linux" --loader /boot/vmlinuz-linux --unicode 'root=MYUUID rw initrd=\boot\initramfs-linux.img'

Disk /dev path is correct (pointing to the SSD where I have Arch and relative EFI partition) and also MYUUID.

Where is my mistake?

Last edited by Franco_64 (2024-11-26 18:50:52)

Offline

#2 2024-11-25 19:27:17

Scimmia
Fellow
Registered: 2012-09-01
Posts: 12,182

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

You're almost certainly using the wrong paths. Do you have /boot/vmlinuz-linux on sdc1? IE, if you're mounting sdc1 to /boot, you are telling it the kernel's at /boot/boot/vmlinuz-linux.

Offline

#3 2024-11-25 19:35:31

Franco_64
Member
From: Milano, Italy
Registered: 2021-11-20
Posts: 49

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

Scimmia wrote:

You're almost certainly using the wrong paths. Do you have /boot/vmlinuz-linux on sdc1? IE, if you're mounting sdc1 to /boot, you are telling it the kernel's at /boot/boot/vmlinuz-linux.

I have to use the path in --loader and --unicode of efibootmgr as relative?

But my error should carry me to a missing kernel (no message), not to a missing entry in bios. I was totally unable to select the SSD to boot on via bios

Last edited by Franco_64 (2024-11-25 19:44:20)

Offline

#4 2024-11-25 20:20:08

d_fajardo
Member
Registered: 2017-07-28
Posts: 1,653

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

No problem during disk partition etc until installing efibootmgr, which however does not "activate" in the EFI bios the entry to boot on Arch.

Certain motherboards don't work well with efibootmgr. This is a fault in the UEFI implementation by the motherboard vendors. You can try a UEFI Shell.

Offline

#5 2024-11-25 20:32:46

Franco_64
Member
From: Milano, Italy
Registered: 2021-11-20
Posts: 49

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

Hmmm... yesterday I've done another attempt to install Arch, and the SSD as a boot disk was visible in bios. So I think the problem is elsewhere.

Offline

#6 2024-11-25 20:57:13

Scimmia
Fellow
Registered: 2012-09-01
Posts: 12,182

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

Franco_64 wrote:
Scimmia wrote:

You're almost certainly using the wrong paths. Do you have /boot/vmlinuz-linux on sdc1? IE, if you're mounting sdc1 to /boot, you are telling it the kernel's at /boot/boot/vmlinuz-linux.

I have to use the path in --loader and --unicode of efibootmgr as relative?

Not exactly. You need to give it the path in the filesystem it's on. You're telling it to look at the filesystem on sdc1, that has nothing to do with where you mount it.

Franco_64 wrote:

But my error should carry me to a missing kernel (no message), not to a missing entry in bios. I was totally unable to select the SSD to boot on via bios

No, most firmware will not display it if the loader is missing, and many will even delete it.

Offline

#7 2024-11-25 21:40:14

Franco_64
Member
From: Milano, Italy
Registered: 2021-11-20
Posts: 49

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

One step beyond.

Now I've redone efibootmgr with entries as you suggest. Bios sees all correctly, but I've obtained a kernel panic.

I think that the problem is here. Transcribe by hand:


/dev/root: Can't open blockdev
VFS: Cannot open root device [UUID] etc etc

(UUID is correct)

Please append a correct "root=" boot option; here are the available partition...

(list of disks and partitions, sdc and all scdx are visible)

I've watch the man page of efibootmgr, but seems there's no an explicit place to insert that parameter.

Last edited by Franco_64 (2024-11-25 21:42:04)

Offline

#8 2024-11-25 22:00:09

Scimmia
Fellow
Registered: 2012-09-01
Posts: 12,182

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

That sounds like it's not loading the inittamfs at all. Make sure you've got that part correct.

Offline

#9 2024-11-26 18:44:49

Franco_64
Member
From: Milano, Italy
Registered: 2021-11-20
Posts: 49

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

IT'OK!

After a lot of "try and error", I'm in.

I don't know exactly why, but in case this can help someone, i report the exact efibootmgr entry, with some comments and considerations.

efibootmgr --create --disk /dev/sdc --label "Arch" --loader /vmlinuz-linux -u 'root=/dev/sdc3 initrd=\initramfs-linux.img'

Notes:

/dev/sdc in the Sata SDD where I have Arch with boot directory with kernel and initramfs in sdc1, swap in sdc2 and root in sdc3

If I use UUID as listed in  /etc/fstab ("root=MYUUID") system don't run (why? And I've read that the assignation of /dev structure can change; I have the risk to have in future an unbootable system?)

I have a lot of kernel warning (bluetooth, audio system...), but I have time to put all in order. Woha!!!

Last edited by Franco_64 (2024-11-26 18:52:04)

Offline

#10 2024-11-26 22:06:12

Funny0facer
Member
From: Germany
Registered: 2022-12-03
Posts: 158

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

To minimize the risk of having an unbootable system, a valid strategy is, to use the same location for the efi file as removeable media does.
esp/EFI/BOOT/BOOTX64.EFI
Be aware: Some UEFI implementations delete the boot entries when the mainboard firmware gets upgraded.

Offline

#11 2024-11-27 01:54:32

Scimmia
Fellow
Registered: 2012-09-01
Posts: 12,182

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

Franco_64 wrote:

If I use UUID as listed in  /etc/fstab ("root=MYUUID") system don't run (why? And I've read that the assignation of /dev structure can change; I have the risk to have in future an unbootable system?)

Probably because the format is root=UUID=12345-1234-12345

This is why posting actual info is important, that probably would have been noticed if you hadn't censored that part.

Funny0facer wrote:

To minimize the risk of having an unbootable system, a valid strategy is, to use the same location for the efi file as removeable media does.
esp/EFI/BOOT/BOOTX64.EFI
Be aware: Some UEFI implementations delete the boot entries when the mainboard firmware gets upgraded.

That doesn't help when using direct EFI stub loading this way.

Offline

#12 2024-11-27 06:07:05

Funny0facer
Member
From: Germany
Registered: 2022-12-03
Posts: 158

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

Scimmia wrote:
Funny0facer wrote:

To minimize the risk of having an unbootable system, a valid strategy is, to use the same location for the efi file as removeable media does.
esp/EFI/BOOT/BOOTX64.EFI
Be aware: Some UEFI implementations delete the boot entries when the mainboard firmware gets upgraded.

That doesn't help when using direct EFI stub loading this way.

Sure? Before posting I found https://wiki.gentoo.org/wiki/EFI_stub#Troubleshooting mentioning this strategy. But I am no expert on this and use grub myself. I only thought it might be worth a try for OP.

Offline

#13 2024-11-27 06:12:43

Head_on_a_Stick
Member
From: The Wirral
Registered: 2014-02-20
Posts: 8,487
Website

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

Funny0facer wrote:
Scimmia wrote:

That doesn't help when using direct EFI stub loading this way.

Sure?

With EFI_STUB loading a kernel command line is needed to point to the root partition but that can't be added with the removable loader location because parameters can only be added via a specific NVRAM entry.

EDIT: pre-coffee nonsense removed.

Last edited by Head_on_a_Stick (2024-11-27 16:28:05)


Para todos todo, para nosotros nada

Offline

#14 2024-11-27 19:54:50

Franco_64
Member
From: Milano, Italy
Registered: 2021-11-20
Posts: 49

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

Scimmia wrote:
Franco_64 wrote:

If I use UUID as listed in  /etc/fstab ("root=MYUUID") system don't run (why? And I've read that the assignation of /dev structure can change; I have the risk to have in future an unbootable system?)

Probably because the format is root=UUID=12345-1234-12345

This is why posting actual info is important, that probably would have been noticed if you hadn't censored that part.

Unfortunately, it's not that simple. I tried using root=UUID=[uuid of root partition], but Arch doesn't boot. I end up in a temporary shell and have to start over.

After a few tries, I gave up, at least for now, and use the command I showed above.

I hope I don't get stuck in a non bootable system when I have configured well all my hardware.

The good news is that now I'm browsing with Arch with xfce and firefox, and this post is made with that.

The bad news is that my keyboard have problems, for example it loose a lot of hits. I open another thread about this.

Offline

#15 2024-11-27 23:08:45

Scimmia
Fellow
Registered: 2012-09-01
Posts: 12,182

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

I'm guessing this is just a terminology thing, but if you actually used the UUID of the partition, that would have to be listed as PARTUUID. UUID is the UUID of the filesystem.

Offline

#16 2024-11-28 16:00:10

Franco_64
Member
From: Milano, Italy
Registered: 2021-11-20
Posts: 49

Re: [SOLVED] efibootmgr doesn't show item in EFI bios

Yes I think it is so. I read the label from /etc/fstab, where is listed as UUID=fb0c6636-8462-459e-bd54-3dd57ba9a19f.

This is the correct label of partition /dev/sdc3, where I mounted root (/).

I make now another try using UUID, but I sincerely haven't understand what is my error.

This in my input (no errors, copy&paste):

efibootmgr --create --disk /dev/sdc --label "Arch Linux" --loader /vmlinuz-linux -u 'root=UUID=fb0c6636-8462-459e-bd54-3dd57ba9a19f rw initrd=\initramfs-linux.img'

EDIT: It works! I don't know what was my error in the previous try...

Problem resolved, thank you!

Last edited by Franco_64 (2024-11-28 16:10:53)

Offline

Board footer

Powered by FluxBB