All of lore.kernel.org
 help / color / mirror / Atom feed
From: Russell Coker <russell@coker.com.au>
To: Christian Kujau <lists@nerdbynature.de>, Ivan Sizov <sivan606@gmail.com>
Cc: Btrfs BTRFS <linux-btrfs@vger.kernel.org>
Subject: Re: Strange behavior after "rm -rf //"
Date: Fri, 12 Aug 2016 13:08:58 +1000	[thread overview]
Message-ID: <A0E51DF2-D230-4847-A541-581A8A9C36DB@coker.com.au> (raw)
In-Reply-To: <alpine.DEB.2.20.14.1608091420150.8131@trent.utfs.org>

http://selinux.coker.com.au/play.html

There are a variety of ways of giving the same result that rm doesn't reject. "/*" Wasn't caught last time I checked. See the above URL if you want to test out various rm operations as root. ;)

On 10 August 2016 9:24:23 AM AEST, Christian Kujau <lists@nerdbynature.de> wrote:
>On Mon, 8 Aug 2016, Ivan Sizov wrote:
>> I'd ran "rm -rf //" by mistake two days ago. I'd stopped it after
>five
>
>Out of curiosity, what version of coreutils is this? The
>--preserve-root 
>option is the default for quite some time now:
>
>> Don't include dirname.h, since system.h does it now.
>> (usage, main): --preserve-root is now the default.
>> 2006-09-03 02:53:58 +0000
>http://git.savannah.gnu.org/cgit/coreutils.git/commit/src/rm.c?id=89ffaa19909d31dffbcf12fb4498afb72666f6c9
>
>Even coreutils-6.10 from Debian/5 refuses to remove "/":
>
>$ sudo rm -rf /
>rm: cannot remove root directory `/'
>
>Christian.

-- 
Sent from my Nexus 6P with K-9 Mail.

  reply	other threads:[~2016-08-12  3:10 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-08 16:30 Strange behavior after "rm -rf //" Ivan Sizov
2016-08-08 17:13 ` Chris Murphy
2016-08-08 18:38   ` Ivan Sizov
2016-08-08 18:52     ` Hugo Mills
2016-08-08 19:00       ` Ivan Sizov
2016-08-09 17:10     ` Chris Murphy
2016-08-09 20:30       ` Duncan
2016-08-21 17:54         ` Ivan Sizov
2016-08-08 19:02 ` Duncan
2016-08-09 23:24 ` Christian Kujau
2016-08-12  3:08   ` Russell Coker [this message]
2016-08-12  6:15     ` Christian Kujau

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=A0E51DF2-D230-4847-A541-581A8A9C36DB@coker.com.au \
    --to=russell@coker.com.au \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=lists@nerdbynature.de \
    --cc=sivan606@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.