Re: [PATCH] Allow cross subvolume reflinks (2nd attempt)

From: Alexander Block
Date: Wed Jun 20 2012 - 13:27:10 EST


On Wed, Jun 20, 2012 at 7:18 PM, Goffredo Baroncelli <kreijack@xxxxxxxxx> wrote:
> Hi Alexander,
>
> On 06/20/2012 12:35 PM, Alexander Block wrote:
>> The patch also does proper vfs mount checks, so cross mount
>> point reflinks are not possible with this patch. It only allows cross
>> reflinks between two subvolumes which are in the same mount point.
>
> Thanks for working on that. What happens if two subvolumes of the same
> filesystem are mounted on two different places ?
>
> I usually do:
>  mount -o subvol=__active /dev/sdX /
>  mount -o subvol=.        /dev/sdX /var/btrfs
>
> So two different subvolumes of the same filesystem (the one on /dev/sdX)
> are mounted on two different places.
>
> Is it possible to do
>  cp --reflink /tmp/foo /var/btrfs/tmp/foo2
This will fail with -EXDEV. The patch explicitly forbids reflinks crossing vfs
mount boundaries.
>
> Thanks
> G.Baroncelli
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/