You are not logged in.

#1 2013-04-28 04:13:14

wolfcore
Member
From: California
Registered: 2012-03-06
Posts: 137

UEFI boot and GRUB2-- cannot reach BIOS menu

I am using UEFI boot and grub. Ever since installation, I haven't been able to open my BIOS menu or my multiboot menu. I am using a Lenovo Z580. When I turn on the laptop, I see the lenovo splash screen and the "Press F2..." on the bottom, and when I press F2 the text changes to "Please wait", but then goes straight to the grub screen. I tried turning off the laptop, taking out the battery for 60 seconds and rebooting (I think that is the way to hard reset), but it didn't change anything. I read on this thread in the Lenovo forums that it might be a hardware problem related to UEFI boot, but I doubt this is something that can't be fixed.

Last edited by wolfcore (2013-04-28 04:13:45)

Offline

#2 2013-04-28 16:34:01

srs5694
Member
From: Woonsocket, RI
Registered: 2012-11-06
Posts: 719
Website

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

There's a bit of code in recent versions of gummiboot that appears to add a menu entry called "Reboot Into Firmware Interface". This doesn't seem to have any effect on my latest test installation under VMWare, but it does work on a computer I've got with an ASUS motherboard. Adding the entry is conditional on finding support in the firmware, so it will work on some computers but not others. In any event, installing gummiboot may give you this interface. If you don't want to use gummiboot as your main boot manager, you could put gummiboot on your ESP and add a GRUB entry to launch gummiboot.

You might also check out the following entry on Ask Fedora, which provides some additional information:

https://ask.fedoraproject.org/question/ … efi-setup/

Offline

#3 2013-04-28 21:49:59

wolfcore
Member
From: California
Registered: 2012-03-06
Posts: 137

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

Before I try to add gummiboot to grub or replace it, is it a problem that

efibootmgr -v

gives no output? Does this mean there are no boot entries?

Offline

#4 2013-04-28 22:20:02

srs5694
Member
From: Woonsocket, RI
Registered: 2012-11-06
Posts: 719
Website

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

That could mean that you're booted in BIOS mode, or at least that the efivars module is not loaded. Do you see a /sys/firmware/efi directory on your system? If not, try "modprobe efivars" as root. If that doesn't produce the directory, then you've almost certainly booted in BIOS mode rather than in EFI mode.

Offline

#5 2013-04-28 23:22:36

wolfcore
Member
From: California
Registered: 2012-03-06
Posts: 137

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

srs5694 wrote:

That could mean that you're booted in BIOS mode, or at least that the efivars module is not loaded. Do you see a /sys/firmware/efi directory on your system? If not, try "modprobe efivars" as root. If that doesn't produce the directory, then you've almost certainly booted in BIOS mode rather than in EFI mode.

The directory is there, I am booted in UEFI mode. I remember deleting the entries from efibootmgr when trying to set up grub/refind/gummiboot. Unfortunately that is when I deleted the BIOS menu entry I think.

How can I cleanly replace Grub with gummiboot? Can I safely pacman -Rns grub, and then install gummiboot following the wiki?

Offline

#6 2013-04-29 09:20:26

teateawhy
Member
From: GER
Registered: 2012-03-05
Posts: 1,138
Website

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

You do not need to uninstall the grub package to install gummiboot, as the packages can coexist. The bootloaders can also coexist on you ESP if you add different entries for them.

Offline

#7 2013-04-29 17:24:22

srs5694
Member
From: Woonsocket, RI
Registered: 2012-11-06
Posts: 719
Website

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

FWIW, there's somebody on another forum (the Mint forum, IIRC) who has a /sys/firmware/efi directory but for whom efibootmgr is completely useless. In his case, /sys/firmware/efi exists, but is empty, which suggests either a kernel bug or an EFI bug. It's conceivable you've got the same problem (and perhaps the same hardware).

Teateawhy is correct that you can install multiple boot loaders/managers. This is one of the advantages of EFI over BIOS: It's easier to get multiple boot programs to coexist.

Another FWIW: I've just added support for the ability to reboot into the EFI firmware into rEFInd. The test version that includes this support is in rEFInd's git repository, and a binary build is here:

http://www.rodsbooks.com/refind-bin-0.6.9.2.zip

Thus, you can try either rEFInd or gummiboot for this; either should work. In both cases, if the firmware supports the feature, a menu item to reboot into the firmware will appear. (In rEFInd, you can disable scanning for this feature by adjusting the "showtools" option in refind.conf, but it will appear by default, if the firmware supports it.)

Offline

#8 2013-05-01 00:11:58

wolfcore
Member
From: California
Registered: 2012-03-06
Posts: 137

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

srs5694 wrote:

FWIW, there's somebody on another forum (the Mint forum, IIRC) who has a /sys/firmware/efi directory but for whom efibootmgr is completely useless. In his case, /sys/firmware/efi exists, but is empty, which suggests either a kernel bug or an EFI bug. It's conceivable you've got the same problem (and perhaps the same hardware).

Teateawhy is correct that you can install multiple boot loaders/managers. This is one of the advantages of EFI over BIOS: It's easier to get multiple boot programs to coexist.

Another FWIW: I've just added support for the ability to reboot into the EFI firmware into rEFInd. The test version that includes this support is in rEFInd's git repository, and a binary build is here:

http://www.rodsbooks.com/refind-bin-0.6.9.2.zip

Thus, you can try either rEFInd or gummiboot for this; either should work. In both cases, if the firmware supports the feature, a menu item to reboot into the firmware will appear. (In rEFInd, you can disable scanning for this feature by adjusting the "showtools" option in refind.conf, but it will appear by default, if the firmware supports it.)

Thank you for the information. I am trying to use the rEFInd binary you linked to, and used the ./install.sh script, but I'm not sure how to have it take precedence over grub. I did

 ~ 69 [3354] % sudo ~/refind-bin-0.6.9.2/install.sh 
[sudo] password for wolfcore: 
Installing rEFInd on Linux....
ESP was found at /boot/efi using vfat
Found rEFInd installation in /boot/efi/EFI/refind; upgrading it.
Installing driver for ext4 (ext4_x64.efi)
Copied rEFInd binary files

Notice: Backed up existing icons directory as icons-backup.
Existing refind.conf file found; copying sample file as refind.conf-sample
to avoid overwriting your customizations.

Installing it!

ALERT: There were problems running the efibootmgr program! You may need to
rename the refind_x64.efi binary to the default name (EFI/boot/bootx64.efi
on x86-64 systems or EFI/boot/bootia32.efi on x86 systems) to have it run!

Existing //boot/refind_linux.conf found; not overwriting.

ALERT:
Installation has completed, but problems were detected. Review the output for
error messages and take corrective measures as necessary. You may need to
re-run this script or install manually before rEFInd will work.

despite the warning, it seems like the files are in the right place and have the right names accoring to the wiki:

rEFInd File Source                            UEFI Destination
/usr/lib/refind/refind_<arch>.efi	      /boot/efi/EFI/refind/refind_<arch>.efi
/usr/lib/refind/config/refind.conf	      /boot/efi/EFI/refind/refind.conf
/usr/share/refind/icons	                      /boot/efi/EFI/refind/icons
/usr/lib/refind/drivers_<arch>	              /boot/efi/EFI/tools/drivers

Here's the tree output of my /boot/efi/EFI/refind directory:

/boot/efi/EFI/refind
├── drivers_x64
│   └── ext4_x64.efi
├── icons
│   ├── arrow_left.icns
│   ├── arrow_right.icns
│   ├── boot_linux.icns
│   ├── ... 
├── icons-backup
│   ├── arrow_left.icns
│   ├── arrow_right.icns
│   ├── boot_linux.icns
│   ├── ... 
├── keys
│   ├── altlinux.cer
│   ├── canonical-uefi-ca.der
│   ├── fedora-ca.cer
│   └── refind.cer
├── refind.conf
├── refind.conf-sample
└── refind_x64.efi

4 directories, 98 files

After doing this I rebooted and nothing had changed, I still had regular GRUB2.
So I did this:

sudo efibootmgr -c -g -d /dev/sda -p 1 -w -L "rEFInd" -l '\EFI\refind\refind_x64.efi'

but got no output. `efibootmgr` and efibootmgr -v` give no output either.

/sys/firmware/efi _is_ populated, and I know that I am booted with UEFI, and rebooting shows no changes.
Any suggestions?

Last edited by wolfcore (2013-05-01 00:17:00)

Offline

#9 2013-05-01 16:42:00

srs5694
Member
From: Woonsocket, RI
Registered: 2012-11-06
Posts: 719
Website

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

Since rEFInd's install.sh relies on a working efibootmgr, and since your efibootmgr is failing, install.sh also failed. As you say, the files are there, but they aren't being launched because they aren't registered. There are several possible solutions to this problem:

  • If you can boot Windows, you can use its "bcdedit" command to register rEFInd as the primary boot loader. You must launch an Administrator Command Prompt window and type "bcdedit /set {bootmgr} path \EFI\refind\refind_x64.efi" to do this.

  • You could rename GRUB (which I gather is booting) and move rEFInd into its place. The details of how to do this depend on the current GRUB program's name.

  • You could use a Linux emergency disc with a different version of efibootmgr to use it to register rEFInd. This solution will work if the problem is with a bug in the version of efibootmgr that you're using, but it won't work if the problem is caused by a firmware bug.

  • You can use an EFI version 2 shell and its "bcfg" command to register rEFInd. See the Arch wiki for details on this command. (Links to EFI shells appear a bit above the heading to which I've linked.)

  • You can create an entry in GRUB that will launch rEFInd. Just treat the rEFInd boot file (EFI/refind/refind_x64.efi) as if it were an OS's boot loader. You'd need to create an entry for rEFInd in the /etc/grub.d/40_custom file and then update the main GRUB configuration file. This option is the one that least likely to cause boot problems should something go wrong.

Offline

#10 2013-05-02 04:44:33

wolfcore
Member
From: California
Registered: 2012-03-06
Posts: 137

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

srs5694 wrote:

You can create an entry in GRUB that will launch rEFInd. Just treat the rEFInd boot file (EFI/refind/refind_x64.efi) as if it were an OS's boot loader. You'd need to create an entry for rEFInd in the /etc/grub.d/40_custom file and then update the main GRUB configuration file. This option is the one that least likely to cause boot problems should something go wrong.

An entry like this?

menuentry "rEFInd" {
    chainloader /EFI/refind/refind_x64.efi
}

Offline

#11 2013-05-02 16:15:24

srs5694
Member
From: Woonsocket, RI
Registered: 2012-11-06
Posts: 719
Website

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

You'd probably need more than that. GRUB 2 is pretty finicky and inconsistent in its requirements, but something like this might work:

menuentry "rEFInd" {
        insmod part_gpt
        insmod chain
        set root='(hd0,gpt1)'
        chainloader /EFI/refind/refind_x64.efi
}

Offline

#12 2013-05-07 04:00:00

wolfcore
Member
From: California
Registered: 2012-03-06
Posts: 137

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

srs5694 wrote:

You'd probably need more than that. GRUB 2 is pretty finicky and inconsistent in its requirements, but something like this might work:

menuentry "rEFInd" {
        insmod part_gpt
        insmod chain
        set root='(hd0,gpt1)'
        chainloader /EFI/refind/refind_x64.efi
}

Alright, we made some progress.

I now do get rEFInd as a boot option and can load it, but I do not get the option to boot to bios. What did you mean by "boot to the firmware"?

Offline

#13 2013-05-07 18:38:55

srs5694
Member
From: Woonsocket, RI
Registered: 2012-11-06
Posts: 719
Website

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

EFI is not BIOS, and most EFI-based computers do not, technically speaking, have a BIOS. (There are a few exceptions, such as Gigabyte's dreadful "Hybrid EFI.") Many computer manufacturers are using the term "BIOS" to refer to their EFIs. I suspect they do this because it's easier than explaining a new acronym ("EFI" or "UEFI") and why the old one ("BIOS") is no longer relevant; but it's technically inaccurate. I refuse to twist the meaning of "BIOS" past its breaking point in this way.

If you see a rEFInd menu entry with a computer chip as an icon and "Reboot to Firmware User Interface" as a label, that's what will reboot into the firmware user interface, which is what you want. If that entry is not there, then either your firmware does not support this feature or it's been disabled by uncommenting the "showtools" option in refind.conf and omitting the "firmware" option from the list.

Offline

#14 2013-05-11 04:27:17

wolfcore
Member
From: California
Registered: 2012-03-06
Posts: 137

Re: UEFI boot and GRUB2-- cannot reach BIOS menu

Yeah, I have no "Reboot to Firmware User Interface" menu entry. I've also looked at refind.conf and have the firmware option enabled sad

Offline

Board footer

Powered by FluxBB