linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andrei Borzenkov <arvidjaar@gmail.com>
To: Dennis Katsonis <dennisk@netspace.net.au>
Cc: Btrfs BTRFS <linux-btrfs@vger.kernel.org>
Subject: Re: Incremental receive completes succesfully despite missing files
Date: Wed, 23 Jan 2019 21:17:02 +0300	[thread overview]
Message-ID: <e5f6086e-83cd-f104-3bb5-c5819790ae4f@gmail.com> (raw)
In-Reply-To: <b36e4ef6-6f07-1430-45a0-df9d44d472fe@netspace.net.au>

23.01.2019 16:52, Dennis Katsonis пишет:
> On 1/23/19 10:25 PM, Andrei Borzenkov wrote:
>> On Wed, Jan 23, 2019 at 1:45 PM Dennis Katsonis <dennisk@netspace.net.au> wrote:
>>> I think my previous e-mail did not go through.  Basically, if it is
>>> assumed that a btrfs-receive operation will result in a subvolume which
>>> matches the source file for file, then this assumption or expectation
>>> won't be met if one deletes files from the subvolume at the receiving
>>> end which is going to be referred to as the parent.
>>>
>>
>> This is oxymoron. btrfs send/receive apply to read-only subvolumes.
>> You are not able to modify them. 
> 
> 
>>
>>> This can happen inadvertently,
>>
>> It cannot. You do not inadvertently make subvolume read-write. 
> It's not the individual steps which happen inadvertently, its that
> particular workflow which can happen (i.e.; someone decides to play
> around with a replicated snapshot, and flips the ro bit to do so).  Any
> subsequent children sent later won't be true replicates on the receiving
> end.
> 
> They would have to either make a habit of not flipping that ro bit at
> all (there is nothing to say don't do it, and there are valid reasons to
> do so) or anticipate they may need that subvolume as a parent anytime in
> the future and that parents must be the same on both ends (there is
> nothing which states that parents have to be identical on both ends for
> btrfs-receive to operate).

You cannot have your cake and eat it. Either you want it to be fool
proof or you want extreme flexibility. In the former case it must block
certain dangerous actions. In the latter case it is up to you - you got
what you asked for.

>  If they do modify ANY subvolume created by
> btrfs-receive, they must remember in the future somehow never to use
> them as parents.
> 

Both NetApp and ZFS distinguish between read-only snapshots and
read-write clones. If you want to obtain read-write access to data in
snapshot you clone it. May be we should at least think about why this
workflow did not change in 25+ years.

Problem discussed in this thread simply cannot happen there.

  reply	other threads:[~2019-01-23 18:17 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-20 10:25 Incremental receive completes succesfully despite missing files Dennis K
2019-01-20 14:04 ` Andrei Borzenkov
2019-01-21 22:23 ` Chris Murphy
2019-01-22  4:36   ` Chris Murphy
2019-01-22  4:54   ` Chris Murphy
2019-01-22  6:00     ` Remi Gauvin
2019-01-22  6:28       ` Chris Murphy
2019-01-22 17:57         ` Andrei Borzenkov
2019-01-22 19:37           ` Chris Murphy
2019-01-22 19:45             ` Hugo Mills
2019-01-23 10:44   ` Dennis Katsonis
2019-01-23 11:25     ` Andrei Borzenkov
2019-01-23 13:52       ` Dennis Katsonis
2019-01-23 18:17         ` Andrei Borzenkov [this message]
2019-01-23 15:25       ` Hans van Kranenburg
2019-01-23 15:32         ` Nikolay Borisov
2019-01-23 16:23           ` Hans van Kranenburg
2019-01-24 10:40             ` Dennis K
2019-01-24 17:22               ` Chris Murphy
2019-01-26  2:43                 ` Dennis Katsonis
2019-01-26 23:09                   ` Chris Murphy
2019-01-27  1:58                     ` Dennis Katsonis
2019-01-23 15:40         ` Remi Gauvin
2019-01-23 16:59           ` Hans van Kranenburg

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=e5f6086e-83cd-f104-3bb5-c5819790ae4f@gmail.com \
    --to=arvidjaar@gmail.com \
    --cc=dennisk@netspace.net.au \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).