* Send/Receive Use Case
@ 2015-06-27 14:04 Vincent Olivier
2015-06-27 14:18 ` Swâmi Petaramesh
2015-06-27 14:21 ` Hugo Mills
0 siblings, 2 replies; 7+ messages in thread
From: Vincent Olivier @ 2015-06-27 14:04 UTC (permalink / raw)
To: linux-btrfs
Hi,
There are 4 things I’m not sure about re:send/receive.
1) Is it possible to first copy things on a file system using rsync and then use send-receive ? And to subsequently mix rsync and send-receive ? Provided that snapshots are made accordingly.
2) Is possible to “send" a snapshot diff to disk and then “receive" it from the said disk into a remote filesystem ? I have two very large and physically distant btrfs filesystems. It would be more economical to juste dump snapshot diffs to disk for transport instead of the network.
3) How are “conflicts” handled by send-receive if at all ?
4) If a file is created, modified and then deleted in-between two snapshots is it ignored by send/receive or does send/receive "re-enacts” the journal exactly ?
Thanks,
Vincent
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Send/Receive Use Case
2015-06-27 14:04 Send/Receive Use Case Vincent Olivier
@ 2015-06-27 14:18 ` Swâmi Petaramesh
2015-06-27 14:21 ` Hugo Mills
1 sibling, 0 replies; 7+ messages in thread
From: Swâmi Petaramesh @ 2015-06-27 14:18 UTC (permalink / raw)
To: Vincent Olivier; +Cc: linux-btrfs
Hi,
Le samedi 27 juin 2015 10:04:28 Vincent Olivier a écrit :
>
> There are 4 things I’m not sure about re:send/receive.
>
> 1) Is it possible to first copy things on a file system using rsync and then
> use send-receive ?
NO. You need to start with a BTRFS snapshot send/receive to be able to
continue with differential send/receives.
> And to subsequently mix rsync and send-receive ?
NOPE.
> 2) Is possible to “send" a snapshot diff to disk and then “receive" it from
> the said disk into a remote filesystem ?
YES.
> 3) How are “conflicts” handled by send-receive if at all ?
No way. Incremental send/receive are possible only if you have the exact
(binary) (read-only) "parent" snapshot on both filesystems. There cannot be
"conflicts" and incremental send/receive is not possible in any other
situation.
> 4) If a file is created, modified and then deleted in-between two snapshots
> is it ignored by send/receive or does send/receive "re-enacts” the journal
> exactly ?
If anything is created/modified/deleted, the medatata being COW, will differ.
Incremental send/receive, being the "binary diff" between filesystem states,
will reflect this difference.
Kind regards.
--
Swâmi Petaramesh <swami@petaramesh.org> http://petaramesh.org PGP 9076E32E
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Send/Receive Use Case
2015-06-27 14:04 Send/Receive Use Case Vincent Olivier
2015-06-27 14:18 ` Swâmi Petaramesh
@ 2015-06-27 14:21 ` Hugo Mills
2015-06-27 14:34 ` Vincent Olivier
1 sibling, 1 reply; 7+ messages in thread
From: Hugo Mills @ 2015-06-27 14:21 UTC (permalink / raw)
To: Vincent Olivier; +Cc: linux-btrfs
[-- Attachment #1: Type: text/plain, Size: 1639 bytes --]
On Sat, Jun 27, 2015 at 10:04:28AM -0400, Vincent Olivier wrote:
> Hi,
>
> There are 4 things I’m not sure about re:send/receive.
>
> 1) Is it possible to first copy things on a file system using rsync and then use send-receive ? And to subsequently mix rsync and send-receive ? Provided that snapshots are made accordingly.
Probably. It depends on exctly how you want to use them.
> 2) Is possible to “send" a snapshot diff to disk and then “receive" it from the said disk into a remote filesystem ? I have two very large and physically distant btrfs filesystems. It would be more economical to juste dump snapshot diffs to disk for transport instead of the network.
Yes, that's perfectly possible.
> 3) How are “conflicts” handled by send-receive if at all ?
There are no conflicts possible, due to the requirement of all the
subvolumes involved in the send/receive process being read-only.
(Actually, that's not quite true -- you can make a subvolume
read/write, and then read-only again. In that case, the receive will
probably fail, leaving the received subvolume in a partially-created
state).
> 4) If a file is created, modified and then deleted in-between two
> snapshots is it ignored by send/receive or does send/receive
> "re-enacts” the journal exactly ?
It'll be ignored. The FS doesn't keep track of how it reached a
particular state -- only what that state is.
Hugo.
--
Hugo Mills | IMPROVE YOUR ORGANISMS!!
hugo@... carfax.org.uk |
http://carfax.org.uk/ |
PGP: E2AB1DE4 | Subject line of spam email
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Send/Receive Use Case
2015-06-27 14:21 ` Hugo Mills
@ 2015-06-27 14:34 ` Vincent Olivier
2015-07-10 19:03 ` Vincent Olivier
0 siblings, 1 reply; 7+ messages in thread
From: Vincent Olivier @ 2015-06-27 14:34 UTC (permalink / raw)
To: linux-btrfs
ok i’ll go home and rethink my life then ;)
> On Jun 27, 2015, at 10:21 AM, Hugo Mills <hugo@carfax.org.uk> wrote:
>
> On Sat, Jun 27, 2015 at 10:04:28AM -0400, Vincent Olivier wrote:
>> Hi,
>>
>> There are 4 things I’m not sure about re:send/receive.
>>
>> 1) Is it possible to first copy things on a file system using rsync and then use send-receive ? And to subsequently mix rsync and send-receive ? Provided that snapshots are made accordingly.
>
> Probably. It depends on exctly how you want to use them.
>
>> 2) Is possible to “send" a snapshot diff to disk and then “receive" it from the said disk into a remote filesystem ? I have two very large and physically distant btrfs filesystems. It would be more economical to juste dump snapshot diffs to disk for transport instead of the network.
>
> Yes, that's perfectly possible.
>
>> 3) How are “conflicts” handled by send-receive if at all ?
>
> There are no conflicts possible, due to the requirement of all the
> subvolumes involved in the send/receive process being read-only.
> (Actually, that's not quite true -- you can make a subvolume
> read/write, and then read-only again. In that case, the receive will
> probably fail, leaving the received subvolume in a partially-created
> state).
>
>> 4) If a file is created, modified and then deleted in-between two
>> snapshots is it ignored by send/receive or does send/receive
>> "re-enacts” the journal exactly ?
>
> It'll be ignored. The FS doesn't keep track of how it reached a
> particular state -- only what that state is.
>
> Hugo.
>
> --
> Hugo Mills | IMPROVE YOUR ORGANISMS!!
> hugo@... carfax.org.uk |
> http://carfax.org.uk/ |
> PGP: E2AB1DE4 | Subject line of spam email
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Send/Receive Use Case
2015-06-27 14:34 ` Vincent Olivier
@ 2015-07-10 19:03 ` Vincent Olivier
2015-07-10 19:11 ` Hugo Mills
0 siblings, 1 reply; 7+ messages in thread
From: Vincent Olivier @ 2015-07-10 19:03 UTC (permalink / raw)
To: linux-btrfs
actually I have another question : is it posssible for a RAID0 fs to “receive” from a “sending” RAID10 ? or do they need to be of the same replication scheme too ?
> On Jun 27, 2015, at 10:34 AM, Vincent Olivier <vincent@up4.com> wrote:
>
> ok i’ll go home and rethink my life then ;)
>
>> On Jun 27, 2015, at 10:21 AM, Hugo Mills <hugo@carfax.org.uk> wrote:
>>
>> On Sat, Jun 27, 2015 at 10:04:28AM -0400, Vincent Olivier wrote:
>>> Hi,
>>>
>>> There are 4 things I’m not sure about re:send/receive.
>>>
>>> 1) Is it possible to first copy things on a file system using rsync and then use send-receive ? And to subsequently mix rsync and send-receive ? Provided that snapshots are made accordingly.
>>
>> Probably. It depends on exctly how you want to use them.
>>
>>> 2) Is possible to “send" a snapshot diff to disk and then “receive" it from the said disk into a remote filesystem ? I have two very large and physically distant btrfs filesystems. It would be more economical to juste dump snapshot diffs to disk for transport instead of the network.
>>
>> Yes, that's perfectly possible.
>>
>>> 3) How are “conflicts” handled by send-receive if at all ?
>>
>> There are no conflicts possible, due to the requirement of all the
>> subvolumes involved in the send/receive process being read-only.
>> (Actually, that's not quite true -- you can make a subvolume
>> read/write, and then read-only again. In that case, the receive will
>> probably fail, leaving the received subvolume in a partially-created
>> state).
>>
>>> 4) If a file is created, modified and then deleted in-between two
>>> snapshots is it ignored by send/receive or does send/receive
>>> "re-enacts” the journal exactly ?
>>
>> It'll be ignored. The FS doesn't keep track of how it reached a
>> particular state -- only what that state is.
>>
>> Hugo.
>>
>> --
>> Hugo Mills | IMPROVE YOUR ORGANISMS!!
>> hugo@... carfax.org.uk |
>> http://carfax.org.uk/ |
>> PGP: E2AB1DE4 | Subject line of spam email
>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Send/Receive Use Case
2015-07-10 19:03 ` Vincent Olivier
@ 2015-07-10 19:11 ` Hugo Mills
2015-07-10 19:12 ` Vincent Olivier
0 siblings, 1 reply; 7+ messages in thread
From: Hugo Mills @ 2015-07-10 19:11 UTC (permalink / raw)
To: Vincent Olivier; +Cc: linux-btrfs
[-- Attachment #1: Type: text/plain, Size: 2368 bytes --]
On Fri, Jul 10, 2015 at 03:03:27PM -0400, Vincent Olivier wrote:
> actually I have another question : is it posssible for a RAID0 fs to “receive” from a “sending” RAID10 ?
Yes, definitely. I do my backups from RAID-1 to single. The send
stream format is based on files, not on the underlying raw storage.
Hugo.
>or do they need to be of the same replication scheme too ?
>
>
>
> > On Jun 27, 2015, at 10:34 AM, Vincent Olivier <vincent@up4.com> wrote:
> >
> > ok i’ll go home and rethink my life then ;)
> >
> >> On Jun 27, 2015, at 10:21 AM, Hugo Mills <hugo@carfax.org.uk> wrote:
> >>
> >> On Sat, Jun 27, 2015 at 10:04:28AM -0400, Vincent Olivier wrote:
> >>> Hi,
> >>>
> >>> There are 4 things I’m not sure about re:send/receive.
> >>>
> >>> 1) Is it possible to first copy things on a file system using rsync and then use send-receive ? And to subsequently mix rsync and send-receive ? Provided that snapshots are made accordingly.
> >>
> >> Probably. It depends on exctly how you want to use them.
> >>
> >>> 2) Is possible to “send" a snapshot diff to disk and then “receive" it from the said disk into a remote filesystem ? I have two very large and physically distant btrfs filesystems. It would be more economical to juste dump snapshot diffs to disk for transport instead of the network.
> >>
> >> Yes, that's perfectly possible.
> >>
> >>> 3) How are “conflicts” handled by send-receive if at all ?
> >>
> >> There are no conflicts possible, due to the requirement of all the
> >> subvolumes involved in the send/receive process being read-only.
> >> (Actually, that's not quite true -- you can make a subvolume
> >> read/write, and then read-only again. In that case, the receive will
> >> probably fail, leaving the received subvolume in a partially-created
> >> state).
> >>
> >>> 4) If a file is created, modified and then deleted in-between two
> >>> snapshots is it ignored by send/receive or does send/receive
> >>> "re-enacts” the journal exactly ?
> >>
> >> It'll be ignored. The FS doesn't keep track of how it reached a
> >> particular state -- only what that state is.
> >>
> >> Hugo.
> >>
--
Hugo Mills | UNIX: Japanese brand of food containers
hugo@... carfax.org.uk |
http://carfax.org.uk/ |
PGP: E2AB1DE4 |
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Send/Receive Use Case
2015-07-10 19:11 ` Hugo Mills
@ 2015-07-10 19:12 ` Vincent Olivier
0 siblings, 0 replies; 7+ messages in thread
From: Vincent Olivier @ 2015-07-10 19:12 UTC (permalink / raw)
To: linux-btrfs
[-- Attachment #1: Type: text/plain, Size: 2500 bytes --]
this is GOOD news . thanks !
> On Jul 10, 2015, at 3:11 PM, Hugo Mills <hugo@carfax.org.uk> wrote:
>
> On Fri, Jul 10, 2015 at 03:03:27PM -0400, Vincent Olivier wrote:
>> actually I have another question : is it posssible for a RAID0 fs to “receive” from a “sending” RAID10 ?
>
> Yes, definitely. I do my backups from RAID-1 to single. The send
> stream format is based on files, not on the underlying raw storage.
>
> Hugo.
>
>> or do they need to be of the same replication scheme too ?
>>
>>
>>
>>> On Jun 27, 2015, at 10:34 AM, Vincent Olivier <vincent@up4.com> wrote:
>>>
>>> ok i’ll go home and rethink my life then ;)
>>>
>>>> On Jun 27, 2015, at 10:21 AM, Hugo Mills <hugo@carfax.org.uk> wrote:
>>>>
>>>> On Sat, Jun 27, 2015 at 10:04:28AM -0400, Vincent Olivier wrote:
>>>>> Hi,
>>>>>
>>>>> There are 4 things I’m not sure about re:send/receive.
>>>>>
>>>>> 1) Is it possible to first copy things on a file system using rsync and then use send-receive ? And to subsequently mix rsync and send-receive ? Provided that snapshots are made accordingly.
>>>>
>>>> Probably. It depends on exctly how you want to use them.
>>>>
>>>>> 2) Is possible to “send" a snapshot diff to disk and then “receive" it from the said disk into a remote filesystem ? I have two very large and physically distant btrfs filesystems. It would be more economical to juste dump snapshot diffs to disk for transport instead of the network.
>>>>
>>>> Yes, that's perfectly possible.
>>>>
>>>>> 3) How are “conflicts” handled by send-receive if at all ?
>>>>
>>>> There are no conflicts possible, due to the requirement of all the
>>>> subvolumes involved in the send/receive process being read-only.
>>>> (Actually, that's not quite true -- you can make a subvolume
>>>> read/write, and then read-only again. In that case, the receive will
>>>> probably fail, leaving the received subvolume in a partially-created
>>>> state).
>>>>
>>>>> 4) If a file is created, modified and then deleted in-between two
>>>>> snapshots is it ignored by send/receive or does send/receive
>>>>> "re-enacts” the journal exactly ?
>>>>
>>>> It'll be ignored. The FS doesn't keep track of how it reached a
>>>> particular state -- only what that state is.
>>>>
>>>> Hugo.
>>>>
>
> --
> Hugo Mills | UNIX: Japanese brand of food containers
> hugo@... carfax.org.uk |
> http://carfax.org.uk/ |
> PGP: E2AB1DE4 |
[-- Attachment #2: Message signed with OpenPGP using GPGMail --]
[-- Type: application/pgp-signature, Size: 801 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2015-07-10 19:12 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-27 14:04 Send/Receive Use Case Vincent Olivier
2015-06-27 14:18 ` Swâmi Petaramesh
2015-06-27 14:21 ` Hugo Mills
2015-06-27 14:34 ` Vincent Olivier
2015-07-10 19:03 ` Vincent Olivier
2015-07-10 19:11 ` Hugo Mills
2015-07-10 19:12 ` Vincent Olivier
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox