Restore GRUB bootloader after Windows install

>>>Restore GRUB bootloader after Windows install

Restore GRUB bootloader after Windows install

Last week I reinstalled Windows XP which was running on my laptop along with Fedora. It’s quite obvious that Microsoft uses own bootloader which is not compatible with Linux, therefore installing Windows overwrites GRUB. Luckily, it is easy to restore.

As I use and like

Fedora, install DVD is required. Download install image, burn it and boot your PC from it.

  1. From main menu select “Rescue Installed System”. Select language, keyboard layout, wheather to start network interfaces or not.
  2. In “Rescue” dialog hit “Continue”.
  3. Message will say “System has been mounted”, click Ok. Hit Return to go to shell.
  4. Another message will say “System mounted on /mnt/sysimage directory”, hit Ok.
  5. In next window select “shell – start shell”, Ok.
  6. Execute following commands in terminal window:
chroot /mnt/sysimage
/sbin/grub-install /dev/sda

NOTE: /dev/sda is boot partition. This is typical value, but if your PC has more than one HDD, you might have to check for correct value.

It also can be useful to review GRUB configuration located at /boot/grub/grub.conf (just in case). Although you can skip if you had your favourite Linux flavour multi-booting successfully before Windows reinstallation.

This guide is step-by-step tutorial for Fedora, but is similar on other Linux distributions like

CentOS, Ubuntu and others.

Further reading:

2016-10-24T10:56:41+00:00 2011-10-01|Fedora|0 Comments

About the Author:

Gytis Repečka is System analyst with passion to open source, electronics & cars, spreading bits about tech, music and privacy.

Leave A Comment