Today after I installed Ubuntu 16.04 via USB on my pre-installed Windows 8 running machine, I was required to restart my computer.

After doing so I wasn´t offered to select an OS, so after looking in the Internet, I came across boot-repair which I ran using the "Try Ubuntu" option in my installation USB.

Following the boot repair I got a message saying,

If your computer directly reboots into Windows, try to change the boot order in your BIOS. If your BIOS does not allow to change the boot order, change the default boot entry of your Windows bootloader. For example, you can boot into Windows then type the following in an admin command prompt:

bcdedit /set {bootmgr} path \EFI\ubuntu\shimx64.efi

So after I reboot my PC, I am receiving the following error message for about 3s, after which it boots automatically into Windows, without letting me access Ubuntu.

Error received while booting after, brand logo, before grub

So I tried the other solution of typing that command in the cmd, to which my surprise, worked, and I am now prompted a window (grub) to choose my OS each time I turn on my PC, but unfortunately, I still receive an error each time, that lasts about 3s, after which I can choose my OS (both are working just fine) and work normally.

Any suggestions to get rid of the error message each time I boot my PC?

  • Does the file .../EFi/BOOT/grubx64.efi actually exist? Mount the EFI partition in a live session and look. The normal place for grub is /EFI/ubuntu/grubx64.efi. Do you have an entry for it (efibootmgr -v)? – ubfan1 Apr 19 '17 at 23:04
  • 1
    Please run the Boot Repair utility and select the "Create BootInfo Summary" option. (DO NOT click "Recommended Repair," at least not yet!) When asked whether to upload the report, click "Yes," and then post the URL provided here. This will give us more details about your configuration, which is required to base an answer on more than guesswork. Also, both the image links point to the same image. Please correct whichever one needs correcting (I suspect the first). – Rod Smith Apr 19 '17 at 23:42
  • For some yet unknown reason; my QNAP does not want to boot from /EFI/Ubuntu so I had to move the files to /EFI/Boot. – Paul Feb 27 at 9:26

Finally managed to solve it.

For the rest, open the terminal

$ sudo bash
$ cd /boot/efi/EFI
$ sudo cp -p ubuntu/grubx64.efi Boot
$ sudo touch ubuntu/grubx64.efi.gbr

After that, I stopped seeing the error message and grub showed up normally (it did before, too, just after seeing that error message for 3s).

  • 2
    can you provide more details of how to go about this? do I boot from liveusb, which partition to mounts,.. thanks – wakandan Aug 8 '17 at 2:42

You should probably fix the boot loader entry itself instead of copying files around. That'll always break when upstream updates something. Try something like this instead:

efibootmgr --create --label Ubuntu --disk /dev/sda1 --loader "\EFI\ubuntu\grubx64.efi"

Where /dev/sda1 corresponds to /boot/efi. For the curious, there's more details in this guide.


Just search for the file and copy it to the location in error.

After some updates and power failures, a HP 8200 was complaining about EFI\BOOT\grub64.efi not being found at boot. I put the SSD in another computer (newer motherboard), this booted just fine, maybe it does a search for the .efi files (?!) So I was able to login, I did a search for the missing file name, copied it to the location in error and it booted just fine:

find /boot -name grubx64.efi


cp /boot/efi/EFI/centos/grubx64.efi /boot/efi/EFI/BOOT/grubx64.efi

The error just said "EFI\BOOT\" but full directory was: "/boot/efi/EFI/BOOT/".

I guess the copy can also be done by putting the hdd in another linux machine.


After a Windows update I could no longer boot into Ubuntu: failed to open /EFI/ubuntu/grubx64.efi

I was able to boot using a Live Ubuntu USB, then:

# find the EFI partition
sudo fdisk -l 

# mount EFI
sudo mount /dev/<partition_name> /mnt

cp -p /cdrom/EFI/grubx64.efi /mnt/EFI/ubuntu

I had to reboot and enable Secure Boot and that did the trick. This was dual booting 18.04 on a Lenovo Thinkpad t470 with Windows 10


Don't try these present above. These are hard and may not work. I also ran into same problem so what I did was took a live USB of Ubuntu and pressed try Ubuntu. Then I went to terminal . There you press this following command .Internet is needed here.

First command: sudo add-apt-repository ppa:yannubuntu/boot-repair && sudo apt get update

Second command : sudo apt-get install -your boot-repair && boot-repair

Then an app will be there. In that you press recommended fix. Then it will fix the grub and reinstall it .here too Internet is must. Then reboot and enjoy dualbooting.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.