All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ken Drummond <btrfs@kendrummond.com>
To: Marc MERLIN <marc@merlins.org>, Maxdamantus <maxdamantus@gmail.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: Fwd: Is there a lightweight copy from one subvolume to another?
Date: Sun, 26 Jan 2014 02:49:22 +1000	[thread overview]
Message-ID: <52E3EB12.8090601@kendrummond.com> (raw)
In-Reply-To: <20140125091705.GB7555@merlins.org>

On 25/01/2014 7:17 PM, Marc MERLIN wrote:
> On Sat, Jan 25, 2014 at 09:50:48PM +1300, Maxdamantus wrote:
>> Due to what I understand is some VFS limitation, you can only
>> reflink-copy between subvolumes under one Linux mountpoint. If
>> /mnt/btrfs1 provides access to all subvolumes, you should be able to
>> copy between them through that path, but you won't be able to copy
>> them across mounts, even `--bind` ones.
>
> That was exactly my understanding too.
>
>>> gargamel [mc]# cp -av --reflink=always misc/olympic Video/misc/
>>> `misc/olympic' -> `Video/misc/olympic'
>>> `misc/olympic/file.avi' -> `Video/misc/olympic/file.avi'
>>> cp: failed to clone `Video/misc/olympic/file.avi' from `misc/olympic/file.avi': Invalid cross-device link
>
> The test above was done in /mnt/btrfs_pool1 and failed as shown here.
>
> Yet
> gargamel:/mnt/btrfs_pool1# btrfs subvolume list .
> ID 257 top level 5 path misc
> ID 258 top level 5 path Video
> ID 259 top level 5 path media
> ID 260 top level 5 path Sound
> ID 261 top level 5 path zoneminder
> ID 262 top level 5 path other
>
> Aah, but it looks like this was my problem:
> 'Preparing to replace coreutils 8.13-3.2 (using .../coreutils_8.21-1_i386.deb) ...
>
> now cp --reflink works as expected.
>
> Thanks,
> Marc
>


If I recall correctly you also need a kernel >= 3.7.  Which I assume you 
have if this is now working.

Ken.

      reply	other threads:[~2014-01-25 16:58 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-25  7:04 Is there a lightweight copy from one subvolume to another? Marc MERLIN
     [not found] ` <CA+TwyweCeUQ7w5MuRLrfHfmJwDbChX5VodsyW8huQ9YuLOAWQA@mail.gmail.com>
2014-01-25  8:50   ` Fwd: " Maxdamantus
2014-01-25  9:17     ` Marc MERLIN
2014-01-25 16:49       ` Ken Drummond [this message]

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=52E3EB12.8090601@kendrummond.com \
    --to=btrfs@kendrummond.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=marc@merlins.org \
    --cc=maxdamantus@gmail.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.