lostwebsite.net blog

Annex to the Lost Website

Arrogant Linux Elitists

with 31 comments

Original post

Did you know that rm -rf / no longer works on recent Ubuntu version? I bet you did not because this command tends to be a bit destructive.

I did not know that. I’ve never been bitten by an accidental rm -rf / but the possibility scares the hell out of me whenever I do a command in my root directory or whenever I write scripts thats erase files.

See the rest at www.lostwebsite.net…


Written by fdgonthier

May 10, 2009 at 3:22 pm

Posted in Debian, Linux, Misc, Ubuntu

Tagged with , , , ,

31 Responses

Subscribe to comments with RSS.

  1. This is the exact same attitude that we hear from countless C programmers when discussing issues of safety in programming. When you mention potential problems with manual memory management for instance (or any other kind of issue, really), you will invariably get the “it’s not a problen if you know what you’re doing” followed by “if you can’t program, use VB.”

    The problem with the “I know what I’m doing” attitude is that nobody is perfect and we *will* screw up. When that happens, especially when it involves dangerous operations, it is a **good** thing that the system requests that we confirm what we meant, that we are not just making a mistake.

    I also really like how one commenter said “Safety if [sic] for bitches.” I guess if you can’t use a keyboard properly, you shouldn’t use the command line anyway, eh?

    Good post man, keep it up.


    May 10, 2009 at 5:37 pm

  2. If this had become the dominant culture of Ubuntu I would be very sad, but it seems to be largely the rantings of one guy with a huge chip on his shoulder and too much time on his hands.

    Most of the other participants in the discussion were quite reasonable about the whole thing.

    Ed Heil

    May 10, 2009 at 10:46 pm

  3. though honestly the angry chip-on-shoulder guy sure did find a lot of kindred spirits in that blog post… that is troubling. But people like that have been Linux dudes forever. The new and special thing about Ubuntu is that that type of person seems to be the exception instead of the rule.

    Ed Heil

    May 10, 2009 at 10:48 pm

  4. “everyone’s a linux elitist prick…except me” –end blog


    May 10, 2009 at 10:58 pm

  5. Why stop there? You should extend this to all directories: I sure don’t want to delete /home, or /usr! But there should still be a flag in the commend to force deletion without those annoying confirmations. “f” seems reasonable enough…something like

    rm -rf /


    May 10, 2009 at 11:10 pm

  6. I’m absolutely not scared about this kind of view having any kind of weight. Even if Ubuntu was community driven, the widening focus of Linux would drive elitists on the fringe. I’m sure that Cannonical, being motivated by $, won’t allow their developers time to deal with elitism such as this.

    But I’m still outraged that some people opposes such an uninvasive safeguard. rm is not broken, in any way. One of its extremely rare use-case has been special-cased. That’s all.


    May 10, 2009 at 11:13 pm

  7. No offense, but you should probably read the man page for rm before you say -f is part of the command. It very well isn’t, it’s a command line option which stands for “force.” That is, forcibly remove everything and don’t prompt me for input. Not to say that your point is invalid, but it helps to actually have all of the facts.


    May 10, 2009 at 11:32 pm

  8. Thank you Mr Randon, for pointing that out in a more sensible way than was was said on Reddit comments.

    I’ll update my post with the explanation of how I think -f is not a safeguard.


    May 10, 2009 at 11:45 pm

  9. @random: facts are for elitists. It is more ‘user-friendly’ and possibly ‘ubuntu-like’ to argue that annyone who uses -f without knowing what it is meant for SHOULD be protected.

    against … against what? his/her own inability or unwillingness to read what -f is for? Well against whatever the elitists expect you will do BEFORE using -f. Does not matter what -f is for.


    May 10, 2009 at 11:46 pm

  10. You could have made your argument without being so petty and long-winded.

    Instead of agreeing with you I just want to tell you to stop crying.


    May 11, 2009 at 12:12 am

  11. I admit that was a little long. I usually try to make shorter posts.


    May 11, 2009 at 12:27 am

  12. Comment sent to
    on Mon May 11 06:29:50 CEST 2009

    It should be noted that it was not Canonical who implemented the
    –preserve-root option for rm, It was implemented by the GNU project.
    chown, chgrp and chmod also support this option by the way.

    Alas, many users do not know the GNU project, and the work we do. An
    example is calling the GNU/Linux operating system for `Linux’, many
    people are not aware about the distinction between the kernel (Linux)
    and that the operating system (GNU) that they are using on a daily
    basis is really GNU, and not Linux. You can read more about this issue
    at http://www.gnu.org/gnu/linux-and-gnu.html and
    http://www.gnu.org/gnu/gnu-linux-faq.html .

    PS. I suggest that you switch to a 100% free operating system like
    gNewSense (http://gnewsense.org/).

    Happy hacking, Alfred M. Szmidt.

    Alfred M. Szmidt

    May 11, 2009 at 12:38 am

  13. “Changes of this nature are destructive to the philosophy of *nix, and is a step closer to the laughable click-the-dialog-box security of Windows Vista.”

    True. This “safeguard”, IMO (been using linux for some 9 years now) is total bullshit, not to mention that it might break some scripts around (a lot of scripts that I have seen, for example, for virtual machines management, etc). Not to mention that it is paradoxal — if I want to FORCE (-f) it to happen, it should happen, and that’s just the way it should be.

    Hopefully this kind of thing will stay only on Ubuntu Desktops, not even on their server-based distros, much less on other distros. It not only goes against the philosophy of the operating system, it also opens a bad precedent for the same thing to happen to other commands. Although that´s true, I guess it can be expected from a distro centered on home users who would normally not even know what a root user is… but such a thing on a server is just unacceptable.

    And yes, the UNIX philosophy is important, and the reason why it has been around for 30 years and hopefully will still be. If you are logged in as root on a UNIX system, it assumes you are the admin and you know what you are doing, so it won´t bother you with redundant questions (the aliases for rm and cp on some distros today are dumb enough already).

    On Ubuntu, “regular people” should use the regular means to delete files. If they manage to open a shell and log as root, it should just assume that they know what they are doing.

    To make it simple: the biggest problem here is not this change on rm (altough bad enough), but the precedent that it opens, so that 5 years from now, we wont have annoying confirmation popups showing up for anything (imagine you managing your server, you try to shut down mysql and it popups a ncurses dialog asking if I am REALLY REALLY SURE I want to shut it down). Imagine you´re a developer or sysadmin and you´re writing some script that is supposed to work on any linux distro – then imagine you having to consider all the different kinds of safety switches that different distros will put on their commands…


    May 11, 2009 at 12:46 am

  14. That comment reaks of elitism. I’m not a “regular user” and I’m pretty happy the system is protecting me from myself because there is no way in hell I will ever want to rm -rf /! I can admit it might break some script, but I would really like to see WTH kind of script would be broken. I’ve used Linux for a while and never seen a script that really meant to remove /.

    Also, there is an HUGE difference between asking for confirmations for potentially bad actions, and preventing catastrophic mistakes. I don’t know why, because a fringe use-case of rm has been special-cased, people suddenly thinks confirmation dialog will pop-up everywhere if a few years. This is B/S.

    Finally, I’d like to point out that this has been implemented in coreutils in 2006. A lot of distributions have that safeguard. Some of your scripts are probably broken already. Sorry.


    May 11, 2009 at 12:59 am

  15. […] View post:  Arrogant Linux Elitists « lostwebsite.net blog […]

  16. […] The rest is here:  Arrogant Linux Elitists « lostwebsite.net blog […]

  17. I may be missing the point of all this but there are two or three things I can’t help but notice:

    1) All important directories like / and /usr/ are owned by root, others in /home/ are owned by other users, so a normal user can’t destroy everything. If the user has root/sudo access it doesn’t really matter what the safeguards are, he’ll manage to deal some serious damage if he really wants to (or is stupid enough to, depending on the point of view). So, in this sense, I do not see why rm should be modified, the safeguards should be elsewhere in the system (i.e., not running as root, not sudoing rm, not owning / as the normal user, etc.)

    2) There’s no real difference between ubuntu and other linux distributions as far as ‘elitism’ is concerned. Ubuntu isn’t a distro for n00bs only: Ubuntu is a no-nonsense distribution that allows you to setup a box in 30 minutes or so and go on with your life being productive in a linux environment. Sometimes, you have to be simply pragmatic. I am a bit tired of the “my distro is bigger than yours” e-penis competition. If you feel like compiling your kernel at each update, by all means, knock your socks off.

    3) Aliasing or otherwise modifying the behavior of cp, rm, ls, is not limited to ubuntu, but I think it’s a really STUPID thing to do as it may change expected behavior and break scripts and confuse users (as if they needed more of that).

    Steven Pigeon

    May 11, 2009 at 9:51 am

  18. 1) If has sudo access and he really wants to do damages then there is still a lot of things he can do that are much more interesting then erasing the root directory. This safeguard is for protecting against silly syntax errors in commands and in scripts. It’s definitely not a security feature.

    In a wider sense, I agree the focus should be put on getting the average user away from the command line and plain super-user mode. That’s what is Ubuntu aiming and I hope they keep it up.

    2) There is indeed nothing different between Ubuntu and other distributions. I wrote this article thinking Ubuntu came in first with this change, then later found the change was done in coreutils, then realized the change was done in coreutils because it was specified in a recent POSIX standard update. So, as far as this change is concerned, there is really no difference between distributions. Every each one of them will eventually get this behavior by default unless they think they are so hardcore and revert the change.

    3) I agree with your point about not changing the behavior of core utilities, but I don’t think it applies in this specific case. I repeat that there is no reason ever the root directory should be unlinked. It doesn’t make sense and never will. I don’t believe this will ever break scripts, except already broken ones.


    May 11, 2009 at 10:08 am

  19. What I mean was not to keep the coreutils from evolving; some would need extra functionality. What I advocate against are silly aliases on ls that makes the listing spew out colors or different formatting, things a script relying on ls cannot cope with except by unaliasing ls in its initialisation phase. In someway, internationalization causes similar problems. If the script expects “matches” and receives “concordances” (or whatever it may be in your locale), it will fail.

    Steven Pigeon

    May 11, 2009 at 10:22 am

  20. I totally agree with that. Nothing should change the exposed interface of core utilities and I think most people working on core utilities are well aware of that.

    But somebody has yet to come to me with a reason / should be erasable. Scripts that do that are most probably broken already, and if there is a script out there that has a good reason to rm -rf /, it can easilly be upgraded to use –no-preserve-root.

    This change doesn’t change the behavior of rm 99.9999999% of the time.


    May 11, 2009 at 10:32 am

  21. If they are elitists, why would they be when Linux is free? I don’t see how free riders should be elitists.


    May 11, 2009 at 10:37 am

  22. I… really don’t see your point.


    May 11, 2009 at 10:44 am

  23. Elitism here refers to dudes that think they cannot possibly make an error typing a command, or while writing a script and brag irrationally about it. I don’t think it has anything to do with free (as in beer).

    @fdgonthier: Neither do I. It doesn’t make sense at all on a running system.

    Steven Pigeon

    May 11, 2009 at 10:46 am

  24. OK Steven. I see your point. But i still think my initial comment makes a point.


    May 11, 2009 at 12:18 pm

  25. I still don’t understand your initial comment. A lot of Linux user love the feeling of power the operating system is giving them. This is true of Linux but also of older commercial versions of Unix. Unix has always been about giving user maximum power and maximum possibilities.

    Elitists fear the new wave of Linux user. Fuelled by the arrival of those new users, Linux develpers add new safeguards easier configuration a slew of changes that make the system easier to use, which, for elistists, also means less powerful. I think this is rarely the case though because the underlying system hasn’t changed that much.


    May 11, 2009 at 1:28 pm

  26. I’m Linux user… thx, I can learn here…


    May 11, 2009 at 6:54 pm

  27. This action is typical of the arrogance of GNU. When I switch between different Unixes, I want the core commands to be as similar as possible, and GNU happily ignores standards and conventions.

    rm -rf / isn’t any more dangerous when logged in as a standard user than running rm -rf . when $PWD=$HOME. While I admire the intention, it doesn’t actual protect you from anything much, and breaks the behaviour of a standard tool. Backups and not being stupid as root are the solutions.

    Oh and GNU/Linux? Come on… as far as my daily interactions go, I should probably call it LaTeX/KDE/Linux before I call it GNU/Linux. Oh, what, you say, they’re built on GNU tools? Well, the GNU tools require glibc too. You can’t have it both ways.


    May 11, 2009 at 10:10 pm

  28. Thank you for your comment Robert!

    This action is typical of the arrogance of GNU. When I switch
    between different Unixes, I want the core commands to be as similar
    as possible, and GNU happily ignores standards and conventions.

    The GNU project follow standards quite stricly (specially if you set
    the POSIXLY_CORRECT enviromental variable), and in this case, we
    follow them as well. There is nothing in the standards (POSIX
    1003.1-2001 and onwards) that prohibits this type of behaviour.

    Another common example of where people think we broke things on
    purpose is the case of `head +2′, POSIX 1003.1-2001 changed this to
    mean something different (show the beginning of the file +2, instead
    of showing the first two lines), so with POSIX 1003.1-2001 and onward,
    you must use `head -n2′ to show the first two lines of a file.

    rm -rf / isn’t any more dangerous when logged in as a standard user
    than running rm -rf . when $PWD=$HOME. While I admire the
    intention, it doesn’t actual protect you from anything much, and
    breaks the behaviour of a standard tool. Backups and not being
    stupid as root are the solutions.

    Maybe it isn’t dangrous as percived, but users requested the feature
    and the feature is useful, so we implemented it. You can still get
    the old behaviour using –no-preserve-root, it is a win-win situation
    for all parties.

    Oh and GNU/Linux? Come on… as far as my daily interactions go, I
    should probably call it LaTeX/KDE/Linux before I call it
    GNU/Linux. Oh, what, you say, they’re built on GNU tools? Well, the
    GNU tools require glibc too. You can’t have it both ways.

    You have fallen in to the common trap of thinking that GNU is a set of
    tools, it isn’t, it is a free operating system. The GNU C library
    (glibc) is one of the many parts of the system that we wrote, to
    complete the system. Linus wrote a important missing part, the Linux
    kernel, and completed the GNU system in the form of GNU/Linux. You
    can read more about this at:

    * http://www.gnu.org/gnu/why-gnu-linux.html

    * http://www.gnu.org/gnu/linux-and-gnu.html

    * http://www.gnu.org/gnu/gnu-users-never-heard-of-gnu.html

    Alfred M. Szmidt

    May 11, 2009 at 10:41 pm

  29. Actually, this was made part of the POSIX standard before the GNU people implemented it. Solaris has the same behavior since.

    The same standard also says that rm -rf . should return an error. GNU coreutils does, and its documented: http://www.gnu.org/software/coreutils/manual/coreutils.html#rm-invocation

    So, I kinda fail to see your point there…


    May 11, 2009 at 10:45 pm

  30. […] one comment In my last post I’ve shown that some people are annoyed at the fact that they can no longer erase their root […]

  31. […] Arrogant Linux Elitists Update It was pointed to me from Reddit and from a commenter that the -f flag in rm -rf is the force flag and […] […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: