public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Dave Chinner <david@fromorbit.com>
To: Steve Bergman <sbergman27@gmail.com>
Cc: Ric Wheeler <rwheeler@redhat.com>,
	Eric Sandeen <sandeen@sandeen.net>,
	xfs@oss.sgi.com
Subject: Re: Questions about XFS
Date: Wed, 12 Jun 2013 07:47:25 +1000	[thread overview]
Message-ID: <20130611214725.GO29338@dastard> (raw)
In-Reply-To: <CAO9HMNFj4Y8bEg3xZct0PTk_4wmGCtuNgFf4m4TR-PnZR_BrNQ@mail.gmail.com>

On Tue, Jun 11, 2013 at 02:17:16PM -0500, Steve Bergman wrote:
> Now about ext3 behavior. (Sorry, I know this is an XFS list, but I've
> been dying to have this clarified. And this does kind of relate to
> XFS.) Not only does data get flushed more frequently. But it gets
> careful treatment. It gets written out immediately before the
> metadata.

That's not careful treatment, that's just ordering. XFS has "careful
treatment", too, but it orders data and metadata differently.

XFS doesn't actually update the inode size until after
the data is written i.e. the size is still zero until the data is
written. That's how XFS orders data vs metadata updates - metadata
that is oly valid after data IO completes is not modified until
after the data IO completes...

Hence if you create a file, write some data and then crash before
the data is written, you'll get the create replayed but nothing else.
i.e. a zero length file. Often it is just the inode size transaction
that is missing from the log - the data is actually on disk and *can
be recovered* if you know what you are doing...

IOWs, the thing that causes people to complain about XFS and zero
length files is that XFS leaves *observable evidence* of data loss
behind, while ext3 and ext4 don't. Hence when people switch to XFS
they actually notice (maybe for the first time!) that running their
laptop battery dead leads to data loss and that their applications
are not behaving safely. They then shoot the messenger (i.e XFS)
for losing data as ext3/ext4 don't "lose data" as they don't leave
any observable evidence of partial file states...

Filesystems behave differently, but those observable differences in
behaviour don't mean one filesystem loses more data than another.
Some filesystems just makes it easier to find evidence of such data
loss and hence make it easier to recover from, not to mention make
it obvious which applications write data unsafely and hence
shouldn't be trusted....

Cheers,

Dave.
-- 
Dave Chinner
david@fromorbit.com

_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

  reply	other threads:[~2013-06-11 21:47 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-11  9:56 Questions about XFS Steve Bergman
2013-06-11 13:10 ` Emmanuel Florac
2013-06-11 13:35 ` Stefan Ring
2013-06-11 13:52 ` Ric Wheeler
2013-06-11 13:59 ` Ric Wheeler
2013-06-11 16:12   ` Steve Bergman
2013-06-11 17:19     ` Ric Wheeler
2013-06-11 17:27       ` Stefan Ring
2013-06-11 17:31         ` Ric Wheeler
2013-06-11 17:41           ` Stefan Ring
2013-06-11 18:03             ` Eric Sandeen
2013-06-11 19:30           ` Steve Bergman
2013-06-11 21:03             ` Dave Chinner
2013-06-11 21:43               ` Steve Bergman
2013-06-11 17:59         ` Ben Myers
2013-06-11 17:28     ` Eric Sandeen
2013-06-11 19:17       ` Steve Bergman
2013-06-11 21:47         ` Dave Chinner [this message]
2013-07-22 14:59       ` Steve Bergman
2013-07-22 15:16         ` Steve Bergman
2013-06-12  8:26     ` Roger Oberholtzer
2013-06-12 10:34       ` Ric Wheeler
2013-06-12 13:52         ` Roger Oberholtzer
2013-06-12 12:12       ` Stan Hoeppner
2013-06-12 13:48         ` Roger Oberholtzer
2013-06-13  0:48       ` Dave Chinner
2013-06-11 19:35 ` Ben Myers
2013-06-11 19:55   ` Steve Bergman
2013-06-11 20:08     ` Ben Myers
2013-06-11 21:57     ` Matthias Schniedermeyer
2013-06-11 22:18       ` Steve Bergman
  -- strict thread matches above, loose matches on Subject: below --
2013-10-25 14:28 harryxiyou
2013-10-25 14:42 ` Emmanuel Florac
2013-10-25 14:57   ` Eric Sandeen
2013-10-25 16:24     ` harryxiyou
2013-10-25 16:44     ` harryxiyou
2013-10-26 10:41     ` Stan Hoeppner
2013-10-27  3:29       ` Eric Sandeen
2013-10-25 16:13   ` harryxiyou
2013-10-25 16:16     ` Eric Sandeen
2007-03-13 13:40 clflush
2007-03-13 15:36 ` Klaus Strebel
2007-03-13 15:53 ` Stein M. Hugubakken
2007-03-13 15:55 ` Eric Sandeen
2007-03-14 16:33 ` Stewart Smith
2007-03-15  4:26   ` Taisuke Yamada
2007-03-15  9:07     ` clflush
2007-03-15 14:41       ` Geir A. Myrestrand
2007-03-16 10:36       ` Martin Steigerwald
2007-03-17  0:47         ` Jason White

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=20130611214725.GO29338@dastard \
    --to=david@fromorbit.com \
    --cc=rwheeler@redhat.com \
    --cc=sandeen@sandeen.net \
    --cc=sbergman27@gmail.com \
    --cc=xfs@oss.sgi.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox