Reinstall grub2

Reinstall grub2

On Software RAID

Prepare chroot

mount /dev/md2 /mnt
mount /dev/md1 /mnt/boot
mount -t dev -o bind /dev /mnt/dev
mount -t proc -o bind /proc /mnt/proc
mount -t sys -o bind /sys /mnt/sys
chroot /mnt

Install grub2

grub2-install /dev/sda

Check if Grub was written in MBR

dd bs=512 count=1 if=/dev/sda 2>/dev/null | strings|grep GRUB

Check Grub 2 for the kernel line

egrep ^menuentry /etc/grub2.cfg | cut -f 2 -d \'

Set new kernel as default boot entry

grub2-set-default 1

Check current boot entry

grub2-editenv list

/home/www/sites/esgr.in/wiki/data/pages/systems/grub2.txt · Last modified: 2018/03/05 05:28 by eServices Greece