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