Linux Btrfs filesystem development
 help / color / mirror / Atom feed
From: Erkki Seppala <flux-btrfs@inside.org>
To: linux-btrfs@vger.kernel.org
Subject: Re: btrfs autodefrag?
Date: Mon, 19 Oct 2015 09:19:48 +0300	[thread overview]
Message-ID: <m49zizfbcsb.fsf@coffee.modeemi.fi> (raw)
In-Reply-To: 20151018144015.GV25907@carfax.org.uk

Hugo Mills <hugo@carfax.org.uk> writes:
>    It has to be disabled because if you enable it, there's a race
> condition: since you're overwriting existing data (rather than CoWing
> it), you can't update the checksums atomically. So, in the interests
> of consistency, checksums are disabled.

I suppose this has been suggested before, but couldn't it store both the
new and the old checksums and be satisfied if either of them match?

The user is probably not happy that a partial write is going to be
difficult to read from the device due to a checksum error, but there is
no promise of recently-overwritten data state with traditional
filesystems either in case of sudden powerdown, assuming there is no
data journaling..

-- 
  _____________________________________________________________________
     / __// /__ ____  __               http://www.modeemi.fi/~flux/\   \
    / /_ / // // /\ \/ /                                            \  /
   /_/  /_/ \___/ /_/\_\@modeemi.fi                                  \/


  reply	other threads:[~2015-10-19  6:19 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-17 16:36 btrfs autodefrag? Xavier Gnata
2015-10-18  5:46 ` Duncan
2015-10-18 12:44   ` Xavier Gnata
2015-10-19  6:04   ` Paul Harvey
2015-10-18 14:24 ` Rich Freeman
2015-10-18 14:40   ` Hugo Mills
2015-10-19  6:19     ` Erkki Seppala [this message]
2015-10-19 11:56       ` Austin S Hemmelgarn
2015-10-19 16:13         ` Erkki Seppala
2015-10-19 19:48           ` Austin S Hemmelgarn

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=m49zizfbcsb.fsf@coffee.modeemi.fi \
    --to=flux-btrfs@inside.org \
    --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