NVRAM changes not persistent with efibootmgr

Chris Murphy lists at colorremedies.com
Fri Jul 11 20:27:21 UTC 2014


On Jul 11, 2014, at 2:09 PM, Gareth Williams <gareth at garethwilliams.me.uk> wrote:

> 
>> There's an argument for totally ignoring NVRAM. rEFInd, an EFI boot manager, produces its boot entries dynamically from fstab, a static configuration file, and the contents of /boot. It ignores NVRAM, there's no constantly modified grub.cfg on the EFI system partition when kernels are updated. 
> 
> That sound worth investigating.  How can it ignore NVRAM? Isn't NVRAM used by the firmware to decide which EFI executable to run? Or does rEFIind simply takes the place of the default EFI/BOOT/BOOTX64.EFI and hence there won't be any reason to have entries in NVRAM?  Maybe I should RTFM instead of asking!

There are a number of ways you can configure it. The firmware's built-in boot manager will go with NVRAM entries. GRUB defers entirely to its grub.cfg even if its stale and doesn't reflect the actual state of the system, e.g. you connect an external device. rEFInd is kinda like the Apple firmware built-in boot manager in that it dynamically produces boot menu entries based on the actual state of the system at the time it loads. So its entries aren't ever stale because it has no configuration file, and it ignores NVRAM entries in favor of the ones it self generates.

But yes, of course you're first at the whim of the firmware to first load rEFInd. That can be done either by an NVRAM entry pointing to rEFInd and setting that entry first in bootorder (also in NVRAM0 which tells the firmware to load rEFInd first. The other way is to obliterate NVRAM contents, and make the only BOOTX64.EFI file actually be rEFInd, but that's tricky if you're using UEFI Secure Boot and is probably a separate thread.


Chris Murphy



More information about the users mailing list