Wednesday, October 14, 2015

Reinstalling Grub on Corrupted Opensuse (even Dual boot) Systems

Boot into Rescue mode from the DVD.
Once the DVD rescue gets to 'login', type:
root

Run fdisk -l to confirm the HD partition order.
We need to mount root. Say that's /sda3
Now mount /sda3 with:
Code:
mount  /dev/sda3  /mnt


To mount the other devices:

mount  --bind  /dev  /mnt/dev
mount  --bind  /proc  /mnt/proc
mount  --bind  /sys  /mnt/sys

If this preparation went well, perform the actual change.
Then chroot:
chroot /mnt
Mount filesystems: mount /proc mount /sys
Install Grub:
grub2-mkconfig -o /boot/grub2/grub.cfg
grub2-install /dev/sda

Then exit and reboot.

Code:
exit
reboot


No comments:

Post a Comment