Get the App
SLTechnology News&Howtos  ›  Servers  › 

What are the causes and solutions after the serious failure of linux server?

Shulou Source: shulou.com Published: 2022-06-01 08:00:39 10月04日 Update

This article is to share with you about the causes of the serious failure of the linux server and how to solve it. The editor thinks it is very practical, so I share it with you to learn. I hope you can get something after reading this article.

1, insert the system installation CD, restart the machine, press the Del key quickly when starting, enter CMOS, and change the start order to CD to start first, so that you can start the Linux installation program, press F5, press the prompt to enter Linux rescue enter, enter the rescue mode, then select the language and keyboard, enter directly, the program prompt has installed the Linux system on the hard disk to / mnt/sysimage, and then a super user prompt appears.

2. Go to the etc directory of the hard disk: cd / mnt/sysimage/etc, and make a backup in case of accident:

Cp shadow shadow.old modifies the property of the shadow file to be writable: chmod + w shadow and then modify it with vi: find the line with root user information: root:... Between the first two colons is the encrypted password. Delete it (the colon cannot be deleted) and save the disk to exit. So the password for root is empty.

Users who do not know how to use vi can take the following methods: find a DOS disk to insert the floppy drive, copy the Shadow to the DOS disk: mcopy shadow Shadow / then modify it with the notepad in the attachment under Windows, be sure to select all files (*. *) to open the file type and save to exit.

Finally, copy it back:

Mcopy a:/shadow mnt/sysimage/etc

3. Change the properties of Shadow back to read-only: chmod-w shadow, then type Exit to exit and take out the CD.

4. For the sake of security, add the password to root in the terminal window after restart.

These are the reasons for the serious failure of the linux server and what the solution is. 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.

Tags: Methods CDs passwords files users prompts causes failures servers services colons that is attributes more knowledge hard drives programs articles systems practical Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Linux MariaDB MySQL Apple Docker