1. Boot centos recovery. Choose appropriate item in boot menu.
http://www.milos.curuvija.com/centos7/authentication/password_recovery.html
First step is to enter the installation CD into the computer and boot from CD drive. Then we will see the screen like on the picture below this text and we should choose Troubleshoot option.
../../_images/pass_recovery_boot.png
After that it will load another screen with a bunch of options and we need to select Rescue a CentOS system.
../../_images/pass_recovery_rescue_option.png
3. Mount original Linux image:
#bind system paths
1 2 3 4 5 6 7 |
mount -o bind /dev /mnt/sysimage/dev mount -o bind /sys /mnt/sysimage/sys mount -o bind /proc /mnt/sysimage/proc mount /dev/md127 /mnt/sysimage/boot |
4. Chroot and fix boot:
1 |
chroot /mnt/sysimage |
1 |
cd /boot |
1 |
dracut --mdadmconf --fstab --add="mdraid" --filesystems "xfs ext4 ext3 tmpfs devpts sysfs proc" --add-drivers="raid1" --force /boot/initramfs-$(uname -r).img $(uname -r) -M |
1 |
dracut --mdadmconf --force /boot/initramfs-$(uname -r).img $(uname -r) |
или
1 |
dracut --mdadmconf --force /boot/initramfs-4.16.13-1.el7.elrepo.x86_64.img 4.16.13-1.el7.elrepo.x86_64 -M |
1 |
nano /etc/yum.conf |
comment
1 |
exclude=kernel* |
update
1 |
yum update |
update kernel
1 |
yum --enablerepo=elrepo-kernel install kernel-ml -y |
https://galaxydata.ru/community/kernel-4-centos-7-ili-io-wait-844
—
Links:
https://cmatthew.net/wiki/Convert_to_raid_1_CentOS_7
https://easy-tutorials.kiev.ua/?p=206