Re: [PATCH] Btrfs: disallow 'btrfs {balance,replace} cancel' on ro mounts

2013-10-11 Thread Hugo Mills
On Fri, Oct 11, 2013 at 03:35:46PM +0600, Roman Mamedov wrote: > On Fri, 11 Oct 2013 11:23:04 +0200 > Stefan Behrens wrote: > > > On Fri, 11 Oct 2013 09:13:24 +0800, Wang Shilong wrote: > > > On 10/11/2013 01:40 AM, Ilya Dryomov wrote: > > > > > > I have a question in my mind. > > > > > > Can w

Re: [PATCH] Btrfs: disallow 'btrfs {balance,replace} cancel' on ro mounts

2013-10-11 Thread Roman Mamedov
On Fri, 11 Oct 2013 11:23:04 +0200 Stefan Behrens wrote: > On Fri, 11 Oct 2013 09:13:24 +0800, Wang Shilong wrote: > > On 10/11/2013 01:40 AM, Ilya Dryomov wrote: > > > > I have a question in my mind. > > > > Can we reach a state that there is operation in progress when filesystem > > has been

Re: [PATCH] Btrfs: disallow 'btrfs {balance,replace} cancel' on ro mounts

2013-10-11 Thread Ilya Dryomov
On Fri, Oct 11, 2013 at 12:28 PM, Remco Hosman - Yerf-IT wrote: > i would expect a RO mount never to write anything to a filesystem. not even > replay a journal (or a seperate option for that). > Its possible that the device is not writable at all, if its a snapshot or a > RO iscsi device of some

Re: [PATCH] Btrfs: disallow 'btrfs {balance,replace} cancel' on ro mounts

2013-10-11 Thread Ilya Dryomov
On Fri, Oct 11, 2013 at 4:13 AM, Wang Shilong wrote: > On 10/11/2013 01:40 AM, Ilya Dryomov wrote: > > I have a question in my mind. > > Can we reach a state that there is operation in progress when filesystem > has been readonly?If we do cancel operations on a ro filesystem, we should > get "No o

Re: [PATCH] Btrfs: disallow 'btrfs {balance,replace} cancel' on ro mounts

2013-10-11 Thread Remco Hosman - Yerf-IT
Op 11-10-2013 11:23, Stefan Behrens schreef: On Fri, 11 Oct 2013 09:13:24 +0800, Wang Shilong wrote: On 10/11/2013 01:40 AM, Ilya Dryomov wrote: I have a question in my mind. Can we reach a state that there is operation in progress when filesystem has been readonly?If we do cancel operations o

Re: [PATCH] Btrfs: disallow 'btrfs {balance,replace} cancel' on ro mounts

2013-10-11 Thread Stefan Behrens
On Fri, 11 Oct 2013 09:13:24 +0800, Wang Shilong wrote: > On 10/11/2013 01:40 AM, Ilya Dryomov wrote: > > I have a question in my mind. > > Can we reach a state that there is operation in progress when filesystem > has been readonly?If we do cancel operations on a ro filesystem, we should > get "

Re: [PATCH] Btrfs: disallow 'btrfs {balance,replace} cancel' on ro mounts

2013-10-10 Thread Wang Shilong
On 10/11/2013 01:40 AM, Ilya Dryomov wrote: I have a question in my mind. Can we reach a state that there is operation in progress when filesystem has been readonly?If we do cancel operations on a ro filesystem, we should get "No operations in progress" . Thanks, Wang For both balance and repl

[PATCH] Btrfs: disallow 'btrfs {balance,replace} cancel' on ro mounts

2013-10-10 Thread Ilya Dryomov
For both balance and replace, cancelling involves changing the on-disk state and committing a transaction, which is not a good thing to do on read-only filesystems. Cc: Stefan Behrens Signed-off-by: Ilya Dryomov --- fs/btrfs/dev-replace.c |3 +++ fs/btrfs/volumes.c |3 +++ 2 files c