Re: FreeBSD 14.1 and UEFI boot ignores bootme flag

From: Daniel Braniss <danny_at_cs.huji.ac.il>
Date: Tue, 13 Aug 2024 13:30:03 UTC

> On 13 Aug 2024, at 15:38, Warner Losh <imp@bsdimp.com> wrote:
> 
> 
> 
> On Tue, Aug 13, 2024, 12:11 AM Daniel Braniss <danny@cs.huji.ac.il <mailto:danny@cs.huji.ac.il>> wrote:
>> hi,
>>         my disk has 2 root partitions, and once I switched to UEFI boot, can’t boot the second partition:
>> (the hardware is a bit old, Dell PowerEdge R710 with bios from 05/22/2018)
>> 
>> store-08# gpart show -l
>> =>        40  5857345456  mfid0  GPT  (2.7T)
>>          40       81920      1  efi  (40M)
>>       81960     8388608      2  root  (4.0G)
>>     8470568     8388608      3  root0  [bootme]  (4.0G)
>>    16859176     8388608      4  d1  (4.0G)
>>    25247784     8388608      5  d2  (4.0G)
>>    33636392  5823709104      6  zfs  (2.7T)
>> 
>> it only boots from partition 2.
>> 
>> so is there any magic?
> 
> 
> Use efibootmgr. Bootme flags are non-standard and have been ignored in UEFI since the start.

I read the man for efibootmgr but it was way above my pay grade :-) 
I tried add/create but got nowhere.

store-08# efibootmgr
BootCurrent: 0000
Timeout    : 0 seconds
BootOrder  : 0002, 0000, 0001
Boot0002* Broadcom NetXtreme II Gigabit Ethernet (BCM5709)
+Boot0000* EFI Fixed Disk Boot Device 1
Boot0001* TSSTcorp DVD+/-RW TS-L633C   

At some point I succeeded in deleting the dvd, but now I see its back.

So how do I add a second boot partition?

(If the sequence look fishy, it’s because I can change the boot sequence via DHCP)


> 
> Or better yet, use boot environments. They are so much nicer than ufs ping pongs.
> 
> Warner
> 
>> thanks,
>>         danny