You are not logged in.
Hi,
I recently installed Arch Linux on my PC alongside Windows 8 x64. After scouring the Arch wiki and various forum posts, I was able to install GRUB2 in UEFI mode on my computer. However, I have to press F9 to get to the GRUB menu or else it just boots into Windows. How can I change this? I am running a HP Envy dv6-7250ca if that makes any difference.
Never assume. It makes an "ass" of "u" and "me".
Offline
What happens when you press F9? Does that take you to the firmware's boot manager menu where you then select grub? If that is the case it is just a matter of setting the priority entry from your bios. This is similar to how you would have chosen the default disk to have booted from in a legacy bios system (MBR).
Offline
F9 brings up a list of boot devices which are:
OS Boot Manager
arch_grub (TOSHIBA MK7575GSX)
Boot From EFI File
I cannot reorder these devices. When I press F10 to go into the BIOS settings, the UEFI Boot Order is:
Internal CD/DVD ROM Drive
USB CD/DVD ROM Drive
USB Diskette on Key/USB Hard Disk
OS boot manager (no capitals on "boot" and "manager" so I'm thinking it might be something different)
! Network Adapter
As you can see, arch_grub or even grub does not appear on this list.
Never assume. It makes an "ass" of "u" and "me".
Offline
OS boot manager should be your UEFI partition.
When you installed grub did you mount the UEFI partition as /boot/Efi
This tends to be make the multiboot instructions a bit more clearer
Offline
I did just that when I was installing it. I can boot into Arch Linux just fine, but Windows still boots first and I have to press F9 to get into GRUB.
Never assume. It makes an "ass" of "u" and "me".
Offline
@DoctorSelar: Change the BootOrder using efibootmgr.
Offline
How would I do that?
Never assume. It makes an "ass" of "u" and "me".
Offline
How would I do that?
RTFM - "man efibootmgr".
Offline
I tried explicitly settings the BootOrder using "sudo efibootmgr -o 0005 (arch_grub), 0000 (Windows)" but Windows overwrote that and started up without going through GRUB.
Never assume. It makes an "ass" of "u" and "me".
Offline
I don't think that windows has the capability of overwriting an entry either when it is not booted or when it is booting. What probably happened is that you didn't actualy change anything, which is particularly likely since the format of the command above is not valid.
The entry numbers should be comma separated with no space, and numbers only (ie. 0005,0000,0001,0002,0003,000A). Running 'efibootmgr' without any options should give you an overview of what is set in your NVRAM. It specifically gives you the current boot order, which is what you should check to make sure you are actually changing something.
As the.ridikulus.rat said above RTFM. All the necessary info is there, and it is how the rest of us learned how to use it.
Offline
I did use it without spaces and brackets, I just did that to improve readability. I used "sudo efibootmgr -o 0005,0000"
Last edited by DoctorSelar (2013-08-27 17:31:24)
Never assume. It makes an "ass" of "u" and "me".
Offline
Some firmwares are broken and reset the boot order, or interface poorly with efibootmgr (which could be an efibootmgr bug, not an EFI bug). In any event, there are some other things you can try:
Update your firmware and try again with efibootmgr. Current EFIs are usually bug-laden, and manufacturers often release updates that fix at least some of these bugs, so they're worth installing.
Use the bcfg command in an EFI version 2 shell to change the boot oder.
Set the default boot loader in Windows via its bcdedit command, as in "bcdedit /set {bootmgr} path \EFI\gentoo\grubx64.efi". (I'm not sure that's the right path, since I don't use GRUB on Arch. Check the path and adjust it as necessary.)
Move or rename EFI/Microsoft/Boot/bootmgfw.efi (such as moving it down one level, to EFI/Microsoft/) and adjust your GRUB configuration to launch it from its new name/location. If necessary, combine this with installing GRUB as EFI/BOOT/bootx64.efi or even as EFI/Microsoft/Boot/bootmgfw.efi.
These options are listed in more-or-less increasing order of desperation. The last one is a last-resort sort of deal; it's necessary only on systems with badly broken EFIs.
Offline
How do I get to an EFI shell? Do I need to install it? It's not an option in either the Setup Utility (F10) or the Boot Device Options (F9).
Never assume. It makes an "ass" of "u" and "me".
Offline
Since I apparently cannot edit my previous post, I have already tried:
Updating firmware (it is currently up-to-date) and re-running efibootmgr
Used the bcdedit command on Windows, nothing happens
Fiddled around with the name/position of the Windows bootloader, only thing that happened (even when I put it back) was that Windows refuses to boot and just kicks me into a repair menu. When I try fixing Windows' bootloader through the command prompt, it comes up with errors and diskpart doesn't detect any disks/volumes/partitions. I installed Windows 8 right before Arch and haven't used it much, so if a reinstall of Windows would help, I would gladly do it
Last edited by DoctorSelar (2013-08-27 16:48:06)
Never assume. It makes an "ass" of "u" and "me".
Offline
Okay, so I was trying to install Arch on another computer and noticed that there was an EFI Shell v1 & 2 option on the Arch install disk. I ran that on the computer that is having trouble. Once I could enter commands, I did bcfg boot -v dump. It came up with
Boot2001 - USB Drive (UEFI)
Boot3001 - EFI Internal HD or SSD
Boot3002 - EFI Internal HD or SSD
Boot2002 - Internal CD/DVD ROM Drive
Error. Unable to read from 'Boot2003' (Not Found).
I used bcfg boot mv 2 1 to swap Boot3002 with Boot3001. I then used exit and restarted my computer. It booted straight to Windows 8. When I went back into the EFI shell and ran bcfg boot -v dump again, the Boot3002 option was missing. When I went to Boot Device Options (F9) the arch_grub entry was missing.
EDIT: I tried re-installing GRUB and using efibootmgr (through the live USB) to manually configure the boot options again. efibootmgr reports all of the proper boot options as well as the proper boot order. However, F9 still does not show arch_grub. On the second boot into the live USB, efibootmgr does not show arch_grub as a boot option although it does refer to a boot option that is non-existent (Boot2003). When I use the live USB to check the EFI partition, it has the correct directories Boot, Microsoft, arch_grub, and grub. When I try to cd to arch_grub or grub, I get the error message:
FAT-fs (sda2): error, fat_get_cluster: invalid cluster chain (i pos 0)
sh: cd: grub: Not a directory
For arch_grub
FAT-fs (sda2): error, fat_get_cluster: invalid cluster chain (i pos 0)
FAT-fs (sda2): Filesystem has been set read-only
sh: cd: arch_grub: Not a directory
Last edited by DoctorSelar (2013-08-28 01:28:14)
Never assume. It makes an "ass" of "u" and "me".
Offline
I would backup the contents of the EFI partition and recreate the filesystem on it. (Note that this may change its ID and require you to reconfigure things). Then put the windows stuff back but reinstall grub etc. for Arch from scratch.
CLI Paste | How To Ask Questions
Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L
Offline
What do you mean by recreate the filesystem on it? Use mkfs.vfat -F32 /dev/sdXX to reformat it?
Never assume. It makes an "ass" of "u" and "me".
Offline
What do you mean by recreate the filesystem on it? Use mkfs.vfat -F32 /dev/sdXX to reformat it?
This would indeed do the trick.
Offline
I would backup the contents of the EFI partition and recreate the filesystem on it. (Note that this may change its ID and require you to reconfigure things). Then put the windows stuff back but reinstall grub etc. for Arch from scratch.
AFAIK UEFI and Windows uses Unique GPT Partition GUIDs so formatting the FS should not be an issue. Better to reinstall grub again, since AFAIK grub uses FSUUID internally to determine its prefix (/boot/grub mostly) where all its modules are stored.
Offline
Okay, should I do Windows or GRUB first?
Never assume. It makes an "ass" of "u" and "me".
Offline
cfr wrote:I would backup the contents of the EFI partition and recreate the filesystem on it. (Note that this may change its ID and require you to reconfigure things). Then put the windows stuff back but reinstall grub etc. for Arch from scratch.
AFAIK UEFI and Windows uses Unique GPT Partition GUIDs so formatting the FS should not be an issue. Better to reinstall grub again, since AFAIK grub uses FSUUID internally to determine its prefix (/boot/grub mostly) where all its modules are stored.
That's good to know about the GUIDs. I'm not certain if you are recommending a different strategy than me or not, though.
CLI Paste | How To Ask Questions
Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L
Offline
Okay, should I do Windows or GRUB first?
Put the Windows stuff back before reinstalling grub so that grub-mkconfig can find it. I doubt it matters whether you put it back before or after grub-install, though.
CLI Paste | How To Ask Questions
Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L
Offline
I've reinstalled the Windows bootloader and GRUB. What should I try next?
Never assume. It makes an "ass" of "u" and "me".
Offline
I've reinstalled the Windows bootloader and GRUB. What should I try next?
You reinstalled windows and grub, and... what happened? This is a pretty terribly vague post. You need to really give a bit more detail than that to get any kind of reasonable response.
Offline
And then everything was back to the start of this thread. I can boot into both Windows and Arch fine, but I need to press F9 to access the GRUB bootloader or else it boots straight into Windows.
Never assume. It makes an "ass" of "u" and "me".
Offline