linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tsutomu Itoh <t-itoh@jp.fujitsu.com>
To: Eric Sandeen <sandeen@redhat.com>
Cc: chris.mason@fusionio.com,
	linux-btrfs <linux-btrfs@vger.kernel.org>,
	Stefan Behrens <sbehrens@giantdisaster.de>,
	David Sterba <dsterba@suse.cz>
Subject: Re: [PATCH, RFC] btrfs-progs: require mkfs -f force option to overwrite filesystem or partition table
Date: Tue, 26 Feb 2013 13:25:11 +0900	[thread overview]
Message-ID: <512C3927.2080708@jp.fujitsu.com> (raw)
In-Reply-To: <512C34CC.3070904@redhat.com>

On 2013/02/26 13:06, Eric Sandeen wrote:
> On 2/25/13 9:55 PM, Tsutomu Itoh wrote:
>> On 2013/02/26 9:07, Eric Sandeen wrote:
>>> On 2/25/13 5:39 PM, Tsutomu Itoh wrote:
>>>> On 2013/02/21 0:37, Stefan Behrens wrote:
>>>>> On Thu, 14 Feb 2013 12:30:03 -0600, Eric Sandeen wrote:
>>>>>> The core of this is shamelessly stolen from xfsprogs.
>>>>>>
>>>>>> Use blkid to detect an existing filesystem or partition
>>>>>> table on any of the target devices.  If something is found,
>>>>>> require the '-f' option to overwrite it, hopefully avoiding
>>>>>> disaster due to mistyped devicenames, etc.
>>>>>>
>>>>>> # mkfs.btrfs /dev/sda1
>>>>>>
>>>>>> WARNING! - Btrfs v0.20-rc1-59-gd00279c-dirty IS EXPERIMENTAL
>>>>>> WARNING! - see http://btrfs.wiki.kernel.org before using
>>>>>>
>>>>>> /dev/sda1 appears to contain an existing filesystem (xfs).
>>>>>> Use the -f option to force overwrite.
>>>>>> #
>>>>>>
>>>>>> This does introduce a requirement on libblkid.
>>>>>>
>>>>>> Signed-off-by: Eric Sandeen <sandeen@redhat.com>
>>>>>
>>>>> This means that it is now required to change all occurrences of
>>>>> "mkfs.btrfs" to "mkfs.btrfs -f" everywhere. Can't we first establish a
>>>>
>>>> I also think so.
>>>> It means -f is not significant to me, I think.
>>>> (Most of my test scripts fails without -f. So I'll always type "mkfs.btrfs -f")
>>>>
>>>> Therefore I want you to revert commit:2a2d8e1962e8b6cda7b0a7584f6d2fb95d442cb6.
>>>>     btrfs-progs: require mkfs -f force option to overwrite filesystem or partition table
>>>>
>>>> How do you think about it?
>>>
>>> What if you submit a patch to look at an environment variable,
>>> BTRFS_CLOBBERS_ALL=1 which causes it to not require -f to overwrite?
>>> Then you can just set it once at the top of your test environment,
>>> and not change every instance?
>>
>> Yes. But,
>>>> (Most of my test scripts fails without -f. So I'll always type "mkfs.btrfs -f")
>> is one example.
>>
>> Almost everyone types "mkfs.btrfs -f" (or BTRFS_CLOBBERS_ALL=1 :)
>> unconditionally, I think.
>> So, I think -f option is almost meaningless.
>>
>>> Otherwise, I guess I think:
>>>
>>> WARNING! - Btrfs v0.20-rc1-212-gf6ef8b5 IS EXPERIMENTAL
>>>
>>> and we need to expect that things might change ...
>>
>> EXPERIMENTAL... It's certainly so.
>> However, I think that we should not add the option that it troubles
>> a lot of people.
>
> Well, I sent it as an RFC.  Chris merged it; I'll defer to his judgement.

Agreed. So, I sent revert request to Chris :)

Thanks,
Tsutomu

>
> Thanks,
> -Eric
>
>> Thanks,
>> Tsutomu
>>
>>>
>>> -Eric
>>>
>>>> Thanks,
>>>> Tsutomu
>>>>
>>>>> time period of 100 years where the -f option is tolerated and ignored,
>>>>> and then in 2113 we require that the users add the -f option?
>>>>>
>>>>> (Just had to do this string replacement everywhere, and had to add -f to
>>>>> xfstest's _scratch_mkfs in common.rc as well). Sigh.
>>>>>



  reply	other threads:[~2013-02-26  4:25 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-14 18:30 [PATCH, RFC] btrfs-progs: require mkfs -f force option to overwrite filesystem or partition table Eric Sandeen
2013-02-14 20:23 ` Chris Mason
2013-02-14 21:20   ` Eric Sandeen
2013-02-20 15:37 ` Stefan Behrens
2013-02-25 23:39   ` Tsutomu Itoh
2013-02-26  0:07     ` Eric Sandeen
2013-02-26  3:55       ` Tsutomu Itoh
2013-02-26  4:06         ` Eric Sandeen
2013-02-26  4:25           ` Tsutomu Itoh [this message]
2013-02-26  7:05             ` Dave Chinner
2013-02-26  8:53               ` Tsutomu Itoh
2013-02-28 16:30               ` mpbtr
2013-02-26 10:37         ` Martin Steigerwald
2013-02-26 19:12           ` Goffredo Baroncelli
2013-02-26 21:16             ` Martin Steigerwald
2013-02-26 12:43     ` David Sterba
2013-02-26 20:23   ` Eric Sandeen

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=512C3927.2080708@jp.fujitsu.com \
    --to=t-itoh@jp.fujitsu.com \
    --cc=chris.mason@fusionio.com \
    --cc=dsterba@suse.cz \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=sandeen@redhat.com \
    --cc=sbehrens@giantdisaster.de \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).