LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   how to recover the serever from a rm -rf (https://www.linuxquestions.org/questions/linux-software-2/how-to-recover-the-serever-from-a-rm-rf-4175459225/)

hitesh_ingole2000 04-23-2013 01:04 AM

how to recover the serever from a rm -rf
 
the commands which i executed are
cd /
rm -rf *
how can i recover from this
when i restarted the server it went in grub mode

unSpawn 04-23-2013 01:25 AM

Quote:

Originally Posted by hitesh_ingole2000 (Post 4936966)
the commands which i executed are
cd /
rm -rf *
how can i recover from this

Restore the system from the last full tested backup. After that ask a senior to change the root password on the machine and configure the appropriate sudo entries for you.

H_TeXMeX_H 04-23-2013 07:38 AM

In case you don't have a backup, testdisk can recover deleted files in many cases.

unSpawn 04-23-2013 12:37 PM

..or Photorec. And this may sound harsh but in case you don't have a backup now you know why you should have. Besides, some people just have to learn not to fat finger stuff or think about what they do (what's a reboot gonna fix?) the hard way.

haertig 04-23-2013 01:36 PM

Quote:

Originally Posted by unSpawn (Post 4937377)
Besides, some people just have to learn not to fat finger stuff...

cd /
rm -rf *

... is one helluva "fat finger"!

unSpawn 04-23-2013 01:54 PM

Yeah, you're right. I'm just trying not to be rude about it.

rknichols 04-23-2013 03:03 PM

Oh, it can indeed be a "fat finger." I once watched someone starting to type, "rm -rf /*something", got as far as "rm -rf /*", then thought better of it and reached for the backspace key. Those oversized, backward "L" shaped <enter> keys come up awfully close to the backspace key.

John VV 04-23-2013 11:01 PM

typing while NOT watching what is being typed

hitting the darn < space> bar after the / will do it every time
darn that thumb it will get you every time:doh::cry:


All times are GMT -5. The time now is 11:00 PM.