-
×InformationNeed Windows 11 help?Check documents on compatibility, FAQs, upgrade information and available fixes.
Windows 11 Support Center. -
-
×InformationNeed Windows 11 help?Check documents on compatibility, FAQs, upgrade information and available fixes.
Windows 11 Support Center. -
- HP Community
- Archived Topics
- Notebooks Archive
- Re: Changing Boot Order on Dual Boot Windows 8 and Ubuntu

Create an account on the HP Community to personalize your profile and ask a question

08-15-2014 01:54 AM
To delete the files, it depends on whether you're currently logged into Linux or Windows.
If on Linux, open the terminal and enter:
sudo rm /boot/efi/EFI/Microsoft/Boot/bootmgfw.efi
sudo rm /boot/efi/EFI/Boot/bootx64.efi
If on Windows and you have the EFI partition mounted on S:, enter:
del S:\EFI\Microsoft\Boot\bootmgfw.efi
del S:\EFI\Boot\bootx64.efi
As for step 8, see this: https://bbs.archlinux.org/viewtopic.php?id=170444
The short version would be to enter these commands into the terminal:
sudo /usr/sbin/grub2-probe --target=hints_string /boot/efi/EFI/Microsoft/Boot/(windowsefifilename.efi)
sudo /usr/sbin/grub2-probe --target=fs_uuid /boot/efi/EFI/Microsoft/Boot/(windowsefifilename.efi)
Remember the output of these two commands, or open a new terminal widow so you could copy from one window to another. Then:
sudo nano /etc/grub.d/40_custom
Inside nano, at the end of the file paste this:
menuentry "Microsoft Windows 8" {
insmod part_gpt
insmod fat
insmod search_fs_uuid
insmod chain
search --fs-uuid --set=root (Output from the first grub2-probe command) (Output from the second grub2-probe command)
chainloader /EFI/Microsoft/Boot/(windowsefifilename.efi)
}
Press ctrl+x to save the file, then finally enter this to reload your bootloader settings:
sudo /usr/sbin/grub2-mkconfig -o /boot/grub2/grub.cfg
08-27-2014 02:56 PM
@GreatEmerald wrote:
There is some sort of a "recovery feature" or so that on every boot sets the very first UEFI load option to point to one of the two locations, in this order:
- \EFI\Microsoft\Boot\bootmgfw.efi
- \EFI\Boot\bootx64.efi
- In the Windows command prompt, update the Windows UEFI entry to point to the new name: bcdedit /set {bootmgr} path \EFI\Microsoft\Boot\bootmgfw.efi~ (adapt to your set name accordingly).
- Optionally, change the name of the Windows boot loader so that you would be certain that it points to the new file location: bcdedit /set {bootmgr} description "Fixed Windows path"
The above did not work for me in (Windows 8.1). I keep getting a error when I run the command in a elevated command prompt everything else worked. Does the command or syntax in bcdedit have to be different in windows 8.1 I already have mint 17 installed and working fine is there a way I could change the above using Linux Mint instead?
Any help appreciated.
Mel
08-27-2014 06:18 PM
I found MY MISTAKE I forgot to put "path" in the command. Sorry to trouble you. I did put a entry in grub.d in the #40 custom and pointed it to the renamed ife file in Win 8.1 so my computer boots up with grub and the default is Linux Mint with a 10 second delay and I can choose to boot Win 8.1 without having to press F9 at bootup.
Thank you for a wonderful tutorial
Mel
09-11-2014 04:24 PM
Hi All,
I have hp cq45 laptop with Windows 8 operating system and i have tried to boot from CD. In bios i did some changes like secure boot disabled then restarted it was asking to type the 4 digit code to select the boot loader but i pressed ESC to cancel the changes. After this changes only the compaq logo and spinning for few seconds then it is showing blank screen.
From the F9 option what option i have to select to go to the normal windows and there is two options 1. OS boot manager 2. Boot From EFI file.
Please help me and you are assistance much appreciated.
Regards,
Set..
09-17-2014 08:27 AM
I tried following the instructions of GreatEmerald, but unfortunately I didn't have any succes.
Whenever Windows boots, it resets itself as the primary boot option in the EFI settings. Both fastboot and secure boot are disabled.
Does anyone have any suggestions, or should I just bring all the brand new HP computers my company has baught back to HP? Computers that aren't able to dual boot between Windows and Linux are just useless.
09-17-2014 08:40 AM - edited 09-17-2014 08:40 AM
Doublecheck that you truly do not have any files named "\EFI\Microsoft\Boot\bootmgfw.efi" and "\EFI\Boot\bootx64.efi" in your EFI SYSTEM partition. There is no way the UEFI could reset itself if these files do not exist, as there is no other way to tell which EFI file is the Windows one!
Unless the UEFI would scan your entire EFI SYSTEM partition and verify checksums, but I don't think anyone in HP would go at such great lengths to prevent dual boot from happening...
09-17-2014 08:48 AM
I did check again, and I do confirm: there are no files named "\EFI\Microsoft\Boot\bootmgfw.efi" or "\EFI\Boot\bootx64.efi" in the EFI system partition.
I did rename the files to "oldbootmgfw.efibak" and "oldbootx64.efibak", just to have a backup in case things would go wrong.
I am as surprised as you: I have not a single clue where HP would get the boot settings from... I think the HP guys owe us an explanation.
09-17-2014 08:48 AM - edited 09-17-2014 08:49 AM
I wrote about my experiance and what I did to get it working on my HP Laptop. here is a link to my blog. there are two articles. I used most of what GreatEmerald has said in this post with a few changes.
Mel
09-17-2014 11:10 AM
Njits, huh, very intersting. What is the model version of your devices, and also what's the output of `sudo /usr/sbin/efibootmgr -v`? Does "OS Boot Manager" successfully load Windows?
Mel_B, thanks, good to see the information being spread further. Also nice addition about GRUB.
