= = = Problem description
Yesterday in order to test some features, executed a program, causing the CentOS system memory spikes, immediately after the Xshell disconnected, then the port can be accessed, is not connected, free-m memory is almost occupied, after a while the system will release memory, But SSH is still not connected, so it was restarted
But found that the time to enter the system is very long, has been stuck in the following interface
650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M02/8B/C8/wKiom1hYmpeTPfp2AABfiMZlsI0147.png "title=" QQ picture 20161220104143.png "alt=" Wkiom1hympetpfp2aabfimzlsi0147.png "/>
Press ESC to see the system boot status, it seems that the error, the first to see is invalid User:root:root, invalid users?
650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M00/8B/C8/wKiom1hYmwDDWfRGAACoLBp-q3Q845.png "title=" QQ picture 20161220104311.png "alt=" Wkiom1hymwddwfrgaacolbp-q3q845.png "/>
= = = Resolution method
Attempt to enter single user mode, same as normal start, unable to enter
Then in the CD into the system CD, boot up the CD-ROM, select the system repair mode
650) this.width=650; "Src=" Http://s5.51cto.com/wyfs02/M02/8B/C4/wKioL1hYniDyYHEOAAQ_2g0Lh3A093.png-wh_500x0-wm_3 -wmp_4-s_792294687.png "title=" Qq20161220105632.png "alt=" Wkiol1hynidyyheoaaq_2g0lh3a093.png-wh_50 "/>
Language and keyboard formats these default
Select CD location, I am locally hanging on the select local CD
650) this.width=650; "Src=" Http://s5.51cto.com/wyfs02/M00/8B/C8/wKiom1hYnm6gTMlkAAAR3UPkwCw780.png-wh_500x0-wm_3 -wmp_4-s_1764725762.png "title=" Qq20161220105749.png "alt=" Wkiom1hynm6gtmlkaaar3upkwcw780.png-wh_50 "/>
Configure the NIC, this optional
Choose whether to let the system find the RHEL system on the hard disk (suspected error may be passwd file corruption, so to mount the disk into repair mode), choose to continue, the picture has been prompted the system is hanging in the/mnt/sysimage, that is, if we want to find the system on the/etc/ passwd file, you will need to enter/MNT/SYSIMAGE/ETC/PASSWD to manipulate the file.
650) this.width=650; "Src=" Http://s1.51cto.com/wyfs02/M00/8B/C4/wKioL1hYnqqii6XVAAAlwEh9W4g192.png-wh_500x0-wm_3 -wmp_4-s_3070892532.png "title=" Qq20161220105905.png "alt=" Wkiol1hynqqii6xvaaalweh9w4g192.png-wh_50 "/>
Start shell
650) this.width=650; "Src=" Http://s2.51cto.com/wyfs02/M02/8B/C4/wKioL1hYnuLwOx1KAAAYsBJIxBI859.png-wh_500x0-wm_3 -wmp_4-s_3473860293.png "title=" Qq20161220105749.png "alt=" Wkiol1hynulwox1kaaaysbjixbi859.png-wh_50 "/>
At this time etc under the passwd more than one-, replace the passwd-with passwd, the last command line input reboot restart, the system starts normally
command: cp/mnt/sysimage/etc/passwd-/mnt/sysimage/etc/passwd
This article from "Sameold" blog, declined reprint!
CentOS does not start properly, prompting invalid User:root:root