On Fri, Nov 27, 2015 at 22:06 Christoph Anton Mitterer
<cales...@scientia.net> wrote:
>
> Hey.
>
> Not sure whether this is intended or not, but it feels at least
> somewhat strange:
>
> Consider I have a readonly snapshot (the only subvol here):
> /btrfs/snapshots/ro-snapshot
> now I want to move it to the dir:
> /btrfs/snapshots/foo/
> i.e.
> mv /btrfs/snapshots/ro-snapshot
> /btrfs/snapshots/foo/
> but the mv complains about read-only filesystem.
>

Not a developer, but I believe this is intended behavior.
Changing the direct parent directory of a subvolume is not a read only
operation: it involves modifying the '..' directory entry.
Renaming the subvolume, or moving the parent directory, modify the
overall fs-hierachy, but do not modify the subvol.

The same is true for normal directories:
mkdir /tmp/dir1
chmod -w /tmp/dir1
mv /tmp/dir1 /tmp/dir2 ## allowed
mkdir /tmp/dir3
mv /tmp/dir2 /tmp/dir3/dir2 ## Permission denied

~ Noah
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to