View

HOWTO Restore GRUB

  1. # Boot on a live CD and open a console. sda1 is supposed to be the partition containing the OS
  2. # 1/ Restore GRUB
  3. mount -t proc none /dev/sda1/proc
  4. mount -o bind /dev /dev/sda1/dev
  5. chroot /dev/sda1/ /bin/bash
  6. /usr/sbin/grub
  7. grub > root(hd0,0)    # 0->a, 1->b …      #1->0, 2->1 …
  8. grub > setup(hd0)
  9. grub > quit
  10. # 2/ Check if partition is bootable
  11. fdsik /dev/sda
  12. fdisk > p      # print the partition table
  13. fdisk > a      # toggle a bootable flag
  14. fdsik > 1
  15. fidsk > w
  16. # 3/ Reboot !! That’s done

You may also like