All of lore.kernel.org
 help / color / mirror / Atom feed
From: Qu Wenruo <quwenruo.btrfs@gmx.com>
To: Chandan Rajendra <chandan@linux.vnet.ibm.com>,
	Qu Wenruo <quwenruo@cn.fujitsu.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: [PATCH] btrfs: Introduce new mount option to disable tree log replay
Date: Tue, 8 Dec 2015 07:51:55 +0800	[thread overview]
Message-ID: <56661B9B.9090607@gmx.com> (raw)
In-Reply-To: <8056366.2GdjmACnsD@localhost.localdomain>



On 12/07/2015 11:38 PM, Chandan Rajendra wrote:
> On Monday 07 Dec 2015 14:06:42 Qu Wenruo wrote:
>> Introduce a new mount option "nologreplay" to co-operate with "ro" mount
>> option to get real readonly mount, like "norecovery" in ext* and xfs.
>>
>> Since the new parse_options() need to check new flags at remount time,
>> so add a new parameter for parse_options().
>>
>
> Hello Qu,
> The patch should add an entry into btrfs_show_options() for 'mount' command to
> be able to display an entry corresponding to 'nologreplay' mount option.

Thanks for the advice.
I just forgot show_mount_options().

And for option to disable "nologreplay", I follow the behavior of xfs 
and ext4 "norecovery" behavior.
Which means no option to disable "norecovery", as it is only used for 
debugging case.
So the only method is to umount it and mount it again.

>
> Even after adding such an entry to btrfs_show_options(),
> the following occurs,
> # mount -o nologreplay,ro /dev/loop6 /mnt/
> # mount | grep loop6
> /dev/loop6 on /mnt type btrfs (ro,relatime,seclabel,nologreplay,space_cache,subvolid=5,subvol=/)
> # mount -o remount,rw /dev/loop6 /mnt/
> # mount | grep loop6
> /dev/loop6 on /mnt type btrfs (rw,relatime,seclabel,nologreplay,space_cache,subvolid=5,subvol=/)
>
> As can be seen from the last line, both 'rw' and 'nologreplay' options are set.
>

I'll double check it, maybe it bypassed btrfs_parse_options(), and 
bypassed the check in it.

Thanks,
Qu

  reply	other threads:[~2015-12-07 23:52 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-07  6:06 [PATCH] btrfs: Introduce new mount option to disable tree log replay Qu Wenruo
2015-12-07 15:38 ` Chandan Rajendra
2015-12-07 23:51   ` Qu Wenruo [this message]
2015-12-07 16:27 ` Eric Sandeen
2015-12-07 16:52   ` Chandan Rajendra
2015-12-07 17:29     ` Eric Sandeen
2015-12-07 20:54       ` Christoph Anton Mitterer
2015-12-07 23:06         ` Eric Sandeen
2015-12-08  0:00           ` Christoph Anton Mitterer
2015-12-08 12:15           ` Austin S Hemmelgarn
2015-12-08 19:20             ` Christoph Anton Mitterer
2015-12-08 20:29               ` Austin S Hemmelgarn
2015-12-07 16:36 ` Austin S Hemmelgarn
2015-12-08  6:08   ` Qu Wenruo
2015-12-08 12:16     ` Austin S Hemmelgarn

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=56661B9B.9090607@gmx.com \
    --to=quwenruo.btrfs@gmx.com \
    --cc=chandan@linux.vnet.ibm.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=quwenruo@cn.fujitsu.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.