7

I can't boot Ubuntu from gub menu after I install Fedora 20 (but I can boot Fedora and windows)

enter image description here

error: can't find command 'linux'
error: can't find command 'initrd'

But I can boot from here

enter image description here

Do you have any idea?

Avinash Raj
  • 78,556
user241258
  • 71
  • 1
  • 3
  • Not wanting to install extra tools without knowing what they do, I found better help on that question: http://askubuntu.com/questions/605738/why-cant-i-boot-into-ubuntu-after-installing-and-then-erasing-fedora – Stéphane Gourichon Oct 22 '15 at 09:05

2 Answers2

7

Recently I was faced with this problem after updating the grub configuration file in Fedora.

To deal with it I had to edit the /boot/efi/EFI/fedora/grub.cfg file as follows:

  • replace all linux with linuxefi

  • replace all initrd with initrdefi

You can also press e while on the grub menu entry to edit it, and do the previous steps.

kiri
  • 28,246
  • 16
  • 81
  • 118
valor
  • 81
  • 1
  • 2
  • Welcome to AskUbuntu. The last two lines are not so clear, did you meant replacing linux by linuxefi? – Luís de Sousa Apr 04 '14 at 12:36
  • @LuísdeSousa, valor's answer seems clear to me and indeed worked once for me (editing at the grub boot prompt). I'm not sure that editing grub.cfg has solid benefits (e.g. after Fedora re-updates grub config such changes may be lost). – Stéphane Gourichon Oct 22 '15 at 09:03
  • 1
    Worked for me after installing Centos 7 side by side with Ubuntu 14.04. It seems the version of GRUB installed with Centos 7 does not have these plain linux and initrd commands. – Autodidact Mar 14 '17 at 13:09
  • This worked for me as well (CentOS 7 along with Ubuntu 14.04) with the minor extra note that editing it via the grub menu is only temporary and you still need to go into CentOS and hand edit the grub.cfg file. Also in CentOS 7 that file is at /boot/efi/EFI/centos/grub.cfg. – Chuck Claunch Jun 02 '17 at 18:07
  • Appreciate this threat is very old, but it just helped me get the latest version of CentOS working with Debian on a dual boot. Is this really the only way to get these two to boot? It's almost like something is being missed on the setup/installation stages... Otherwise I am just not going to be using GRUB2 from now on, as this has been a design problem for nearly 5-6 years without being solved. – john smith Feb 17 '19 at 12:11
0

The Boot Repair utility, as user192938 suggests, may fix the problem. Another possibility is to install my rEFInd boot manager, which will take over as the primary boot program rather than have a "battle of the GRUBs," which is what you've got now. (Each distribution's GRUB is trying to be dominant, and as it happens, the Fedora GRUB has misconfigured the Ubuntu boot.) In fact, you can choose to install and manually configure any of several EFI boot loaders for Linux, so take your pick!

Rod Smith
  • 44,284
  • 7
  • 63
  • 105