Ubuntu – “Unable to install GRUB in /dev/sda” when installing GRUB

grub2system-installation

I recently bought a shiny new Lenovo Yoga 2 Pro and I want to dual boot it with Ubuntu for studying purposes. Its built-in OS is Windows 8.1 and it has a 256GB SSD.

I've made a separate 90GB partition just for Ubuntu and a live USB to install it.

The first time everything seemed to work great, I solved the wifi issued by blacklisting ideapad_laptop, the installation went flawlessly and Ubuntu worked fine.

When I got up the next morning and turned on my laptop it booted into Windows right away without ever showing the GRUB menu. So I tried to reset, and checked my partitions with the Disk Manager and everything looked fine. Since I couldn't find a solution online I went ahead and formatted the partition to try and install again. This time and every time since, the installation was aborted and I got a fatal error saying:

Unable to install GRUB in /dev/sda
Executing `grub-install /dev/sda` failed.
This is a fatal error.

Can anyone please suggest a solution to this problem?
If any further information is needed I would be happy to provide it.
Thanks.

When installing I get the following in details:

ubuntu kernel: [ 1946.372741] FAT-fs (sda2): error, fat_get_cluster: invalid cluster chain (i_pos 0).
ubuntu grub-installer: error: Running 'grub-install --force failed.

Best Answer

I just had this problem installing Ubuntu 14.04 from a USB stick to a hard drive.

The problem was the USB stick was /dev/sda, installing to the hard drive /dev/sdb

Even though the installer knew to install to /dev/sdb, it then tried to install grub to the MBR on /dev/sda, and failed. The workaround was to go back to the menu, try again, say NO to automatically install to MBR of first hard drive and manually tell it /dev/sdb.

Then everything worked.

Related Question