1

I know this question has been asked several times, but none of the answers seem to be working in my case.

I have win 10 and Ubuntu. but there is no dual boot menu. GRUB does not show in the bootup. it automatically boots into windows, if I go to the BIOS in the startup and from the boot menu choose my HDD, it boots into Ubuntu!

Question is how to fix GRUB and have it show the OS select menu in the startup?

In the GRUB customizer, it does not show Windows either.

What I did: on a blank hard disk, I installed win 10, disabled fastboot, installed UBUNTU 16 from a USB flash memory. While installing Ubuntu, there was no option for "Install Ubuntu alongside windows boot manager", so I choose something else and installed ubuntu successfully.

This is my hard disk:

user@ubuntpc:~$ sudo lsblk -o NAME,FSTYPE,SIZE,MOUNTPOINT,LABEL
NAME    FSTYPE   SIZE MOUNTPOINT     LABEL
sda             2,7T
├─sda1          128M                 
├─sda2 ntfs       1T                 HD1 
├─sda3 ntfs       1T                 HD2 
├─sda4 ntfs   713,2G                 HD3 
└─sda5 swap    33,2G [SWAP]          
sdb           232,9G         
├─sdb1 ntfs     450M                 Recovery 
├─sdb2 vfat      99M     
├─sdb3           16M                 
├─sdb4 ntfs    99,5G             
├─sdb5 ext4      75G /               
└─sdb6 ntfs    57,9G             

(I have 3TB HDD, I use it only for the UBUNTU SWAP and DATA files. I have 250 GB SSD I use it for both windows and ubuntu os).

NIMISHAN
  • 1,575
  • 4
  • 19
  • 28

1 Answers1

2

So I found the error and resolved it.

reason: while installing ubuntu I had not deactivated SECURE BOOT. [i think] or it also might have been that asus mobo CRM (legacy mode) was active for USB flash that had ubuntu on it.

this has led that win was in EFI and ubuntu was in legacy.

solution: I followed this guide

$ sudo mount /dev/sdb5 /mnt
$ sudo mkdir -p /mnt/boot/efi
$ sudo mount /dev/sdb2 /mnt/boot/efi
$ sudo mount --bind /dev /mnt/dev
$ sudo mount --bind /proc /mnt/proc
$ sudo mount --bind /sys /mnt/sys
$ sudo mount --bind /run /mnt/run
$ modprobe efivars
$ sudo chroot /mnt
# apt-get install grub-efi-amd64
# grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=ubuntu --recheck --no-floppy --debug

changed the sdb? accordingly.

it did the trick. computer now shows the boot-manager, with options for win and ubuntu.