1

I have three OS on my system in dual-boot: Windows 8, Linux Deepin 2014, and Ubuntu 14.04 LTS. Somewhere along the way, booting to windows no longer worked, and some time after that, only the Deepin boot worked.

So I re-installed Ubuntu (because it was my main working OS) and now it works again, but Windows is not booting. I tried fixing it with boot-repair but it failed, complaining: No boot loader is installed in the MBR of /dev/sda.. Here's the full report from it.

Now I'm afraid to even restart because who knows if Ubuntu is going to boot...

What should I do?

yuvi
  • 1,047
  • 3
  • 17
  • 33

1 Answers1

1

First - fix Windows booting, second - fix GRUB2. Let's start with Windows booting:

Boot from Windows 7 DVD and after choosing language options, start the console: "Repair your computer" -> "Use recovery tools..." -> "Command prompt". In the console run the following command to re-install Windows bootloader:

> bootrec /fixmbr

Then rebuild bootsector if it is corrupted, just to be sure:

> bootrec /fixboot

After that You should be able to boot into Windows through the standard Windows booting - no GRUB, no questions - just power on and boot into Windows as in single-boot Windows machine. Now, when Windows boots correctly, it is time to re-install GRUB2:

Boot from Ubuntu Desktop CD and run Terminal. Then mount the / filesystem of existing Ubuntu installation (/dev/sda2 in this example, but Your case may be different) as well as additional resources:

$ sudo mkdir /mnt/ubuntu
$ sudo mount /dev/sda2 /mnt/ubuntu
$ sudo mount --bind /dev /mnt/ubuntu/dev
$ sudo mount --bind /proc /mnt/ubuntu/proc
$ sudo mount --bind /sys /mnt/ubuntu/sys

After that, chroot to mounted directory and reinstall GRUB2:

$ sudo chroot /mnt/ubuntu
# grub-install /dev/sda
# exit

Reboot and GRUB2 is back. GRUB2 installation should automatically detect all available operating systems and put them into GRUB2 boot menu.