rm -rf /

  • SpooF
  • ٩๏̯͡๏۶
  • Bronze Member
  • User avatar
  • Posts: 3422
  • Loc: Richland, WA

Post 3+ Months Ago

So has anyone every ran 'rm -rf /' for the hell of it, or on accident?
  • Don2007
  • Web Master
  • Web Master
  • Don2007
  • Posts: 4923
  • Loc: NY

Post 3+ Months Ago

I've never done that. Why don't you try it & let us know the results.
  • SpooF
  • ٩๏̯͡๏۶
  • Bronze Member
  • User avatar
  • Posts: 3422
  • Loc: Richland, WA

Post 3+ Months Ago

haha, Im think I might just do that
  • joebert
  • Fart Bubbles
  • Genius
  • User avatar
  • Posts: 13504
  • Loc: Florida

Post 3+ Months Ago

From what I gather via rm --help, you'ld have to pass it a --no-preserve-root flag for it to do anything.

It also says using rm instead of shred will leave "the file" recoverable, but it doesn't say anything about "filesystems" being recoverable.
  • Don2007
  • Web Master
  • Web Master
  • Don2007
  • Posts: 4923
  • Loc: NY

Post 3+ Months Ago

-f Attempt to remove the files without prompting for confirmation, regardless of the file's permissions. If the file does not exist, do not display a diagnostic message or modify the exit status to reflect an error. The -f option overrides any previous -i options.

That's all the FreeBSD man page says.
  • joebert
  • Fart Bubbles
  • Genius
  • User avatar
  • Posts: 13504
  • Loc: Florida

Post 3+ Months Ago

Here's the two options of interest from Ubuntus man page for rm.

Code: [ Select ]
      --no-preserve-root
              do not treat ‘/’ specially
 
       --preserve-root
              do not remove ‘/’ (default)
 
  1.       --no-preserve-root
  2.               do not treat ‘/’ specially
  3.  
  4.        --preserve-root
  5.               do not remove ‘/’ (default)
  6.  
  • spork
  • Brewmaster
  • Silver Member
  • User avatar
  • Posts: 6254
  • Loc: Seattle, WA

Post 3+ Months Ago

There were a couple of videos on YouTube a while back that depict screencasts of people running rm -rf / on a fresh Linux install. The results are pretty funny; it doesn't completely wipe out the system since many root-level files are protected and cannot be deleted, but it does end up wiping out all language files and many important configuration files. The UI environment takes a big hit.
  • AnarchY SI
  • Web Master
  • Web Master
  • User avatar
  • Posts: 2521
  • Loc: /usr/src/MI

Post 3+ Months Ago

should also be noted that simply running "rm -rf /" will do nothing more than
Quote:
rm: cannot remove root directory `/'
as it lacks the proper privileges ;]
  • kc0tma
  • o|||||||o
  • Web Master
  • User avatar
  • Posts: 3318
  • Loc: Trout Creek, MT

Post 3+ Months Ago

So the moral of the story is: don't give idiots root access.
  • Rabid Dog
  • Web Master
  • Web Master
  • User avatar
  • Posts: 3245
  • Loc: South Africa

Post 3+ Months Ago

AnarchY SI wrote:
should also be noted that simply running "rm -rf /" will do nothing more than
Quote:
rm: cannot remove root directory `/'
as it lacks the proper privileges ;]


You read my mind! :)
  • SpooF
  • ٩๏̯͡๏۶
  • Bronze Member
  • User avatar
  • Posts: 3422
  • Loc: Richland, WA

Post 3+ Months Ago

What about this? it wont try to remove the directory root, just everything inside of it.
Code: [ Select ]
rm -rf /*


I think I might throw up a instance on my mosso account to check this out here soon.

Post Information

  • Total Posts in this topic: 11 posts
  • Users browsing this forum: No registered users and 6 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.