All of lore.kernel.org
 help / color / mirror / Atom feed
From: Duncan <1i5t5.duncan@cox.net>
To: linux-btrfs@vger.kernel.org
Subject: Re: Planning for subvolumes of subvolumes and btrfs send/receive
Date: Mon, 21 Apr 2014 05:21:08 +0000 (UTC)	[thread overview]
Message-ID: <pan$dba25$fcce76df$e65f293a$ec25f425@cox.net> (raw)
In-Reply-To: 20140420194627.GO7884@merlins.org

Marc MERLIN posted on Sun, 20 Apr 2014 12:46:27 -0700 as excerpted:

> Long story short, I'm wondering if I can use btrfs send to copy sub
> subvolumes (by snapshotting a parent subvolume, and hopefully getting
> all the children underneath). My reading so far, says no.

I don't do much with subvolumes and absolutely nothing with send/receive 
myself, but from what I've read, no, for the simple case (but see below) 
that cannot work.

The reason is that snapshots (including the read-only snapshot done for a 
send) stop at subvolume borders.

In the large-internal-write-NOCOW-file dedicated subvolume case, that's a 
positive, since the dedicated subvolume can be used to avoid snapshotting 
the nocow stuff on the subvolume when snapshotting a parent, but in this 
case the same subvolume property is a negative.


Now somebody *DID* mention multi-subvolume sends, and indeed, checking 
the manpage, there appears to be allowance for that by naming multiple 
subvolumes (and multiple clone-sources when doing the incremental), 
*BUT*, there appears to be no corresponding allowance for multiple 
subvolume snapshotting, so your script would need a "for subvol in 
$subvols" type construct at least for the snapshotting, and once you do 
that, you might as well do multiple sends as well, as that's likely to be 
more robust than a the larger all-in-one send, if one of the subvolume 
sends/receives fails for some reason.

-- 
Duncan - List replies preferred.   No HTML msgs.
"Every nonfree program has a lord, a master --
and if you use the program, he is your master."  Richard Stallman


  reply	other threads:[~2014-04-21  5:21 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-20 19:46 Planning for subvolumes of subvolumes and btrfs send/receive Marc MERLIN
2014-04-21  5:21 ` Duncan [this message]
2014-04-21  5:39 ` Chris Murphy
2014-04-21  5:48   ` Marc MERLIN
2014-04-21  6:08     ` Chris Murphy
2014-04-21 21:51       ` Marc MERLIN

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='pan$dba25$fcce76df$e65f293a$ec25f425@cox.net' \
    --to=1i5t5.duncan@cox.net \
    --cc=linux-btrfs@vger.kernel.org \
    /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.