In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
The main content of this article is to explain "how to delete important files by Linux". Interested friends may wish to have a look. The method introduced in this paper is simple, fast and practical. Next, let the editor take you to learn "how to delete important files by mistake by Linux"!
Background
When using Linux, there will be some misoperations, resulting in the system can not be used properly, such as the deletion of an important dependent library, or the deletion of rpm and so on. Record the specific operation steps here for future reference.
Meaning
Learn to use the rescue mode to restore the system when you mistakenly delete important files in the Linux system.
Detailed explanation of case
When we delete the Linux system critical library file, how to restore it, for example, here we delete the file / lib64/libc.so.6 to see what changes have taken place in the system.
Delete / lib64/libc.so.6 this file after many basic commands can not be used, including shutdown has been unable to perform, it seems that this is a very dangerous operation, delete such a file will cause our system not to work properly. Some people say that rebooting may solve the problem. Let's see if rebooting can solve this problem. We just turn off the power and turn it on.
After rebooting, the system is stuck in this interface and cannot continue.
Now use rescue mode to fix this problem.
First, when rebooting, press esc to enter Boot Menu when the following interface appears. (ps: hand speed should be fast. Press it before the progress bar is full. You can only press it once. Even if you press too much, you can't get in.)
The arrow keys select the third item CD-ROM Drive, CD-ROM boot
Then choose the third rescue mode.
Select a language. The default English is fine.
Select No to skip network port detection
Click to continue
This reminds us that the root directory in rescue mode is not our previous root directory, but / mnt.sysimage is my previous root directory. If you want to change back to the previous root directory, you need to execute the chroot / mnt/sysimage command.
Once again remind us of the problem with the root directory
At this point, choose to start the shell process so that we can use the command.
At this time, we use ls to find that this command works, indicating that there is a / lib64/libc.so.6 file in rescue mode.
At this point, all we have to do is copy the file to the previous directory.
Select reboot and press enter to restart the system.
At this time, our just deleted file came back, and the commands that were not easy to use were all good, and the repair was successful.
Summary
If we mistakenly delete some system important files, we can use the rescue mode to recover, because there are all kinds of files needed by the system in the rescue mode. Of course, the rescue model is not just these functions, this is the most basic use of it.
At this point, I believe that everyone on the "Linux mistakenly deleted important files how to do" have a deeper understanding, might as well to the actual operation of it! Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!
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.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.