linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: Christoph Hellwig <hch@infradead.org>,
	xfs@oss.sgi.com, linux-fsdevel@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: do_sync() and XFSQA test 182 failures....
Date: Fri, 31 Oct 2008 16:31:23 -0400	[thread overview]
Message-ID: <20081031203123.GA11514@infradead.org> (raw)
In-Reply-To: <20081031001249.GM4985@disturbed>

On Fri, Oct 31, 2008 at 11:12:49AM +1100, Dave Chinner wrote:
> Right - that's exactly where we should be going with this, I think.
> I'd suggest two callouts, perhaps: ->sync_data and ->sync_metadata.
> The freeze code can then still operate in two stages, and we can
> also use then for separating data and inode writeback in pdflush....
> 
> FWIW, I mentioned doing this sort of thing here:
> 
> http://xfs.org/index.php/Improving_inode_Caching#Avoiding_the_Generic_pdflush_Code
> 
> I think I'll look at redoing do_sync() to provide a custom sync
> method before trying to fix XFS....

And you weren't the first to thing of this.  Reiser4 for example
has bad a patch forever to turn sync_sb_inodes into a filesystem method,
and I think something similar is what we want.  When talking about
syncing we basically want a few things:

 - sync out data, either async (from pdflush) or sync
   (from sync, freeze, remount ro or unmount)
 - sync out metadata (from pdflush), either async or sync
   (from sync, freeze, remount ro or unmount)

and then we want pdflush / sync / etc call into it.  If we are doing
this correctly this would also avoid having our own xfssyncd.

And as we found out it's not just sync that gets it wrong, it's also
fsync (which isn't part of the above picture as it's per-inode) that
gets this utterly wrong, as well as all kinds of syncs, not just the
unmount one.  Combine this with the other data integrity issues Nick
found in write_cache_pages I come to the conclusion that this whole area
needs some profound audit and re-architecture urgently.



  parent reply	other threads:[~2008-10-31 20:31 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-30  8:50 do_sync() and XFSQA test 182 failures Dave Chinner
2008-10-30 22:46 ` Christoph Hellwig
2008-10-31  0:12   ` Dave Chinner
2008-10-31  0:48     ` Dave Chinner
2008-10-31 20:31     ` Christoph Hellwig [this message]
2008-10-31 21:54       ` Dave Chinner
2008-10-31 22:22         ` Christoph Hellwig
2008-10-31  4:02 ` Lachlan McIlroy
2008-10-31 13:06   ` Dave Chinner

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=20081031203123.GA11514@infradead.org \
    --to=hch@infradead.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --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;
as well as URLs for NNTP newsgroup(s).