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

Solution to accidentally delete / root directory by centos

2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Network Security >

Share

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

Accidentally delete the / root of centos with rm-rf during the test.

Delete the / root directory, the system will not crash, it can start normally, but it just looks uncomfortable!

Solution:

1. Create / root directory directly; mkdir / root

two。 Copy the hidden files under / etc/skel/ to the / root directory; cp / etc/skel/.bash* / root

3. Just restart it.

4. Be careful when using rm-rf in the production environment, and it is best to test in the test environment to make sure there is no problem before using it!

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

Network Security

Wechat

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

12
Report