Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What are the steps to fix boot errors in CentOS 6.x?

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

This article is to share with you about CentOS 6.x boot error repair steps, the editor feels very practical, so share with you to learn, I hope you can learn something after reading this article, say no more, follow the editor to have a look.

5.X generally, you can enter single-user mode by adding a word "single" at the end of the following line in grub.

The code is as follows:

Kernel / vmlinuz-2.6.18-8.el5 single ro root=LABEL=/ rhgb quiet

Then 6.x goes like this:

The code is as follows:

Kernel / vmlinuz-2.6.32-220.el6.x86_64 ro root=UUID=eb7b1e63-5e8c-4e6c-b87c-140a310e8224 rd_NO_LUKS rd_NO_LVM LANG=en_US.UTF-8 rd_NO_MD quiet SYSFONT=latarcyrheb-sun16 rhgb crashkernel=auto KEYBOARDTYPE=pc KEYTABLE=us rd_NO_DM

Add "single" directly to the back and still can't get into the system. The result is as follows:

Later, it was changed to kernel / vmlinuz-2.6.18-8.el5 single ro root=LABEL=/ rhgb quiet following the example of 5.x.

The following figure prompts:

A hint means there must be a way! To be a live horse doctor, change the kernel line in grub to

The code is as follows:

Kernel / vmlinuz-2.6.18-8.el5 single ro root=LABEL=/ rhgb quiet rdshell

The system can actually give a debug shell, as shown in the figure:

That's easy. It is perfectly normal to restore etc/passwd decisively.

Steps:

The code is as follows:

# mount dev/sda2 tmp first needs to know how your system is partitioned and where to put the etc

# cd tmp

/ etc#cat passwd- > passwd

OK, restart the system directly and run the system normally.

The above is what the CentOS 6.x boot error repair steps are, and the editor believes that there are some knowledge points that we may see or use in our daily work. I hope you can learn more from this article. For more details, please follow the industry information channel.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report