projg2 / installkernel-gentoo

Gentoo fork of installkernel from debianutils
GNU General Public License v2.0
19 stars 7 forks source link

Mention partition name in the UEFI entry label #23

Closed Biosias closed 8 months ago

Biosias commented 8 months ago

I'm currently testing virt-firmware approach on our machines and I've encoutered following problem.

In case of systems with multiple EFI partitions (for example 3), when I want to run make install for each of them. 3 UEFI entries will be generated with the same label. This makes me unable to determine which entry is for which partition from the UEFI boot menu. Would it be possible to also append partition name to the Label of UEFI entry.

Examples:

Current case looks like this:

Boot0004* 6.8.1-gentoo  HD(1,GPT,05b19d4b-a222-4da4-8c43-51550d8cc179,0x800,0x7f800)/File(\EFI\Gentoo\kernel-6.8.1-gentoo-plain.efi)
Boot0005* 6.8.1-gentoo  HD(1,GPT,b14c4a45-26bd-47e1-8208-23020a5acb8a,0x800,0x7f800)/File(\EFI\Gentoo\kernel-6.8.1-gentoo-plain.efi)
Boot0006* 6.8.1-gentoo  HD(1,GPT,9977ef65-df4d-4afc-9323-f53329067ca4,0x800,0x7f800)/File(\EFI\Gentoo\kernel-6.8.1-gentoo-plain.efi)

Output of the solution could look something like this:

Boot0004* 6.8.1-gentoo-sda1  HD(1,GPT,05b19d4b-a222-4da4-8c43-51550d8cc179,0x800,0x7f800)/File(\EFI\Gentoo\kernel-6.8.1-gentoo-plain.efi)
Boot0005* 6.8.1-gentoo-sdb1  HD(1,GPT,b14c4a45-26bd-47e1-8208-23020a5acb8a,0x800,0x7f800)/File(\EFI\Gentoo\kernel-6.8.1-gentoo-plain.efi)
Boot0006* 6.8.1-gentoo-sdc1  HD(1,GPT,9977ef65-df4d-4afc-9323-f53329067ca4,0x800,0x7f800)/File(\EFI\Gentoo\kernel-6.8.1-gentoo-plain.efi)
Nowa-Ammerlaan commented 8 months ago

Since sda, sdb, sdc etc are dependent on the order the kernel loads the disks, I would rather choose something invariant. Would it also be acceptable to add the PARTUUID or the PARTLABEL/LABEL to the title instead?

Biosias commented 8 months ago

Yes, you are right. I think LABEL would be the best in terms of readability.

Nowa-Ammerlaan commented 8 months ago

Fixed in: https://github.com/projg2/installkernel-gentoo/commit/d652c3292c1354e5bd9da1db2efe7207a743ea6a

Let me know if this works better for you.