8

This keep happening when I install the Ubuntu as a dual boot for my laptop. I get a black that appears when booting with the following messages.

Minimal BASH-like line editing is supported.   
For the first word, TAB lists possible command completions. 
Anywhere else TAB lists possible device or file completions.  


grub>  
grub>  
grub>  
grub>  
grub>  
grub>  
grub>  
grub>  
grub> 

I have to enter these commands like this:

grub> set prefix=(hd0,msdos6)/boot/grub/ 
grub> insmod normal 
grub> normal

And the GRUB menu appears. How to make my GRUB menu appear without having to type those command at my GRUB prompts?

I tried sudo grub-install and it give me this error message.

enter image description here

I tried to check if i have chosen the right disk, which come two possibilities, /dev/sda1 and /dev/sda6, but neither of these two works, and they gave the same error message.

/dev/sda1/

enter image description here

/dev/sda6

enter image description here

6
+50

After booting the hard way, open a terminal with Ctrl+Alt+T and install boot-repair:

sudo add-apt-repository ppa:yannubuntu/boot-repair
sudo apt-get update
sudo apt-get install -y boot-repair && boot-repair

Then type boot-repair and a menu will appear:

boot-repair menu.png

Select the recommended option.

If your system boots normally after recommended repair great. If not post the link to the problems reported.


Caveats

On some systems this annoyance can occur:

If this happens to you, visit the link for a solution.

  • You're welcome. Don't forget to award the bounty... :) – WinEunuuchs2Unix Jan 1 at 2:10
  • I will wait for another answer. If there is no one aswer after the bounty near expired, i will awarded to you :). – gagantous Jan 1 at 4:46
  • 1
    @gagantous Waiting for better answers is a good idea. Indeed, it allowed me to think of ways to improve my answer, which I just did. – WinEunuuchs2Unix Jan 1 at 14:08
4

Once booted into Ubuntu run the following command:

sudo grub-install /dev/sda

This assumes that /dev/sda is your disk that matches (hd0,msdos6) in your grub command, which it likely is. You can run a graphical program like gnome-disks or gparted to confirm it's the correct disk.

The command grub-install will detect any partitions and re-install your bootloader so it can find the bootable partitions.

  • didnt work, see my updated question. – gagantous Dec 31 '18 at 1:02
  • You always install grub to a drive like sda, almost never to a partition like sda1 or sda6. – oldfred Jan 1 at 15:56
1

First step would be, after logged in - into Ubuntu in terminal type:

sudo grub-install /dev/sda (or /dev/whatever-harddisk)

wait until installation of grub is finish, then ...

Second step would be, to update grub with:

sudo update-grub2

wait until updating of grub-config-file is finish.

reboot

Then restart of ubuntu should be no problem and you pass by into Ubuntu gdm screen or lightdm screen for desktop again.

  • When you perform this answer to repair grub, then boot-repair is not a must ... – dschinn1001 Jan 3 at 22:42

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.