LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 04-23-2013, 01:04 AM   #1
hitesh_ingole2000
LQ Newbie
 
Registered: Apr 2013
Posts: 6

Rep: Reputation: Disabled
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
 
Old 04-23-2013, 01:25 AM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
Quote:
Originally Posted by hitesh_ingole2000 View Post
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.
 
Old 04-23-2013, 07:38 AM   #3
H_TeXMeX_H
LQ Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301
In case you don't have a backup, testdisk can recover deleted files in many cases.
 
Old 04-23-2013, 12:37 PM   #4
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
..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.
 
1 members found this post helpful.
Old 04-23-2013, 01:36 PM   #5
haertig
Senior Member
 
Registered: Nov 2004
Distribution: Debian, Ubuntu, LinuxMint, Slackware, SysrescueCD, Raspbian, Arch
Posts: 2,331

Rep: Reputation: 357Reputation: 357Reputation: 357Reputation: 357
Quote:
Originally Posted by unSpawn View Post
Besides, some people just have to learn not to fat finger stuff...
cd /
rm -rf *

... is one helluva "fat finger"!
 
Old 04-23-2013, 01:54 PM   #6
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
Yeah, you're right. I'm just trying not to be rude about it.
 
Old 04-23-2013, 03:03 PM   #7
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: Rocky Linux
Posts: 4,780

Rep: Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213Reputation: 2213
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.
 
Old 04-23-2013, 11:01 PM   #8
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,627

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
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
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
FreeBSD 8 as a serever khodeir *BSD 6 07-18-2010 02:01 AM
Configuring network on blade serever (CentOS) skn Linux - Networking 11 11-16-2009 05:56 AM
OH NO !!! Can I recover this ? bgeddy Linux From Scratch 6 07-09-2007 09:39 PM
CVSNT on win2000 serever with AD and with SSh veeraalin General 1 02-21-2006 03:14 AM
filesystem: recover or not to recover? bdp Linux - General 3 06-06-2003 03:40 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:41 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration