public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Dave Chinner <david@fromorbit.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: Paul Anderson <pha@umich.edu>,
	Sean Thomas Caron <scaron@umich.edu>,
	xfs@oss.sgi.com
Subject: Re: [PATCH 2/2 v2] xfs: log all dirty inodes in xfs_fs_sync_fs
Date: Wed, 21 Dec 2011 08:21:06 +1100	[thread overview]
Message-ID: <20111220212106.GY23662@dastard> (raw)
In-Reply-To: <20111220200841.GA2788@infradead.org>

On Tue, Dec 20, 2011 at 03:08:41PM -0500, Christoph Hellwig wrote:
> Since Linux 2.6.36 the writeback code has introduces various measures for
> live lock prevention during sync().  Unfortunately some of these are
> actively harmful for the XFS model, where the inode gets marked dirty for
> metadata from the data I/O handler.
> 
> The older_than_this checks that are now more strictly enforced since
> 
>     writeback: avoid livelocking WB_SYNC_ALL writeback
> 
> by only calling into __writeback_inodes_sb and thus only sampling the
> current cut off time once.  But on a slow enough devices the previous
> asynchronous sync pass might not have fully completed yet, and thus XFS
> might mark metadata dirty only after that sampling of the cut off time for
> the blocking pass already happened.  I have not myself reproduced this
> myself on a real system, but by introducing artificial delay into the
> XFS I/O completion workqueues it can be reproduced easily.
> 
> Fix this by iterating over all XFS inodes in ->sync_fs and log all that
> are dirty.  This might log inode that only got redirtied after the
> previous pass, but given how cheap delayed logging of inodes is it
> isn't a major concern for performance.
> 
> Signed-off-by: Christoph Hellwig <hch@lst.de>

Looks OK now.

Reviewed-by: Dave Chinner <dchinner@redhat.com>

-- 
Dave Chinner
david@fromorbit.com

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

  reply	other threads:[~2011-12-20 21:21 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20111218154936.GA17626@infradead.org>
2011-12-18 15:49 ` [PATCH 1/1] xfs: log the inode in ->write_inode calls for kupdate Christoph Hellwig
2011-12-20 21:19   ` Dave Chinner
2011-12-23 15:55   ` Mark Tinguely
2011-12-23 17:58   ` Ben Myers
2011-12-28 21:35   ` Hans-Peter Jansen
2011-12-28 21:39     ` Christoph Hellwig
2011-12-18 15:50 ` [PATCH 2/2] xfs: log all dirty inodes in xfs_fs_sync_fs Christoph Hellwig
2011-12-18 20:03   ` Sean Thomas Caron
2011-12-18 20:09     ` Christoph Hellwig
2011-12-18 22:17   ` Dave Chinner
2011-12-18 22:32     ` Christoph Hellwig
2011-12-20 20:08   ` [PATCH 2/2 v2] " Christoph Hellwig
2011-12-20 21:21     ` Dave Chinner [this message]
2011-12-23 15:55     ` Mark Tinguely
2011-12-23 21:47     ` Ben Myers
2011-12-26 12:13       ` Dave Chinner
2011-12-29 15:42         ` Ben Myers
2011-12-29 21:44           ` Dave Chinner
2012-01-03 15:48             ` Mark Tinguely
2011-12-21 17:40 ` sync fixes Christoph Hellwig

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=20111220212106.GY23662@dastard \
    --to=david@fromorbit.com \
    --cc=hch@infradead.org \
    --cc=pha@umich.edu \
    --cc=scaron@umich.edu \
    --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