After CentOS is started, go to the grub command interface.
After the centos host is started, only the "grub>" prompt may appear, and further system startup cannot be completed. There are two clear cases:
1. grub configuration files are lost or configuration errors occur.
2. the boot program in the MBR record is damaged
As a result, the default Grub boot program in Linux cannot boot normally.
·:
1. If you do not know where your boot partition is located, enter root (hd0, and press the tab key. The following information is displayed. You need to try the partition location of type 0x83, because all 0x83 partitions may be/root partitions, that is, 0, 1, and 4 partition locations.
2. Start the test from root (hd0, 0), enter the kernel/vm and press the tab key. If you can complete the test, it indicates that it is correct, and then enter root =/dev/sda1, {Note: (hd0, 0) =/dev/sda1 (hd0, 1) =/dev/sda2}
3. Enter initrd/ini and press the tab key to complete
·
4. Enter the boot command
·
5. If the following information is displayed, the selected root partition is incorrect. Restart and continue.
·
6. Because the content you just wrote is temporarily written into the memory, you need to write it again. Change root =/dev/sda1 to root =/dev/sda2, and then enter the boot command. Then you can enter the system.