From: Brian Foster <bfoster@redhat.com>
To: linux-xfs@vger.kernel.org
Subject: [PATCH 0/2] xfs: don't preempt writeback on page errors
Date: Wed, 31 Oct 2018 10:01:53 -0400 [thread overview]
Message-ID: <20181031140155.17996-1-bfoster@redhat.com> (raw)
Hi all,
Here's a stab at a fix for the issue demonstrated by the previously
posted xfstest [1]. This basically just filters out error returns to
write_cache_pages() and returns the first encountered error from the
higher level ->writepage[s]() call. AFAICT the end result should be the
same as today in the event of a persistent writeback error.
I'm not totally sure if this is the best solution, but it's the simplest
that comes to mind. FWIW, this patch changes error return behavior
unconditionally. A slightly modified approach might be to only filter
errors as such on integrity writeback so background writeback will
presumably behave as it always has, while allowing fsync/unmount to
process the address space in one writeback job.
If there's a reason we want to preserve the current writeback behavior
in general, I suppose we could consider more involved options like tag
any inode that preempts writeback due to error and then make sure we
process/scan/clear such inodes of delalloc blocks before we unmount
(and/or on fsync). Either way, we may also want to consider rate
limiting the "page discard" errors if it's more likely we dump a bunch
at once.
Thoughts?
Brian
[1] https://marc.info/?l=linux-xfs&m=154031860122440&w=2
Brian Foster (2):
xfs: add writepage map error tag
xfs: don't preempt writeback sequence on single page wb error
fs/xfs/libxfs/xfs_errortag.h | 4 +++-
fs/xfs/xfs_aops.c | 19 ++++++++++++++-----
fs/xfs/xfs_error.c | 3 +++
3 files changed, 20 insertions(+), 6 deletions(-)
--
2.17.2
next reply other threads:[~2018-10-31 23:00 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-10-31 14:01 Brian Foster [this message]
2018-10-31 14:01 ` [PATCH 1/2] xfs: add writepage map error tag Brian Foster
2018-10-31 14:01 ` [PATCH 2/2] xfs: don't preempt writeback sequence on single page wb error Brian Foster
2018-10-31 23:02 ` Dave Chinner
2018-11-01 14:17 ` Brian Foster
2018-11-01 21:37 ` Dave Chinner
2018-11-02 11:42 ` Brian Foster
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=20181031140155.17996-1-bfoster@redhat.com \
--to=bfoster@redhat.com \
--cc=linux-xfs@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