From: Mike Snitzer <snitzer@redhat.com>
To: dm-devel@redhat.com
Subject: Re: [PATCH for-dm-3.14-fixes 3/8] dm thin: set flag if metadata is out of space
Date: Fri, 21 Feb 2014 09:35:41 -0500 [thread overview]
Message-ID: <20140221143540.GE4578@redhat.com> (raw)
In-Reply-To: <20140221142022.GC13298@debian>
On Fri, Feb 21 2014 at 9:20am -0500,
Joe Thornber <thornber@redhat.com> wrote:
> NACK.
>
> It's odd that the interface has dm-thin telling dm-thin-metadata
> whether or not it's out of space (yet thin-metadata clears it
> itself). So I don't like the patch from that point of view, though
> it's a minor quibble.
Yeap, minor quibble.. I can expose an interface that lets me reset it to
false after resize -- from thin. Seems unnecessary given the expected
short lifetime of this code (see below).
> More importantly, running out of metadata space is a serious error
> that causes a transaction to be aborted. Any thins that contained
> metadata changes in that aborted transaction need to be umounted and
> fscked. We should not transistion back to WRITE mode just because
> more metadata space is provided since this doesn't force the sys admin
> to repare/check the thins that have lost io.
This is an incremental change that just adds the control of whether the
metadata is out of space or not. The current kernel code cannot give us
that info. This is a stop gap until you implement the reserve that
gives us a concrete value to test for to _know_ that metadata is out of
space. That is why I said as much in the patch header. Once we have
that this change can be reverted. But for now it is needed.
> So I'm nacking because I think you're planning to special case running
> out of metadata space, rather than treating it the same as any other
> metadata error (eg, a failed write to the metadata device).
>
> As we've discussed the correct thing to do when getting any error from
> a metadata operation is:
>
> i) Abort the current transaction
>
> ii) flick to READ_ONLY mode. Any thin devices that lost writes due
> to the abort will reflect this by erroring every subsequent
> REQ_FUA or REQ_FLUSH.
>
> iii) Set a needs_check flag in the metadata to prevent a table
> reload transitioning to WRITE mode.
I'm not seeing how running out of space on metadata is any different
than any other metadata operation that failed. The transaction is
aborted, as soon as that happens all bets are off on upper level data
consistency. So while thin metadata may be perfectly fine, it is still
prudent for the user to check their data.
Patch 7 impsoes this constraint. It provides all 3 points you listed
above.
next prev parent reply other threads:[~2014-02-21 14:35 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-21 2:55 [PATCH for-dm-3.14-fixes 0/8] dm thin: address a few fundamental problems Mike Snitzer
2014-02-21 2:55 ` [PATCH for-dm-3.14-fixes 1/8] dm thin: synchronize the pool mode during suspend Mike Snitzer
2014-02-21 13:58 ` Joe Thornber
2014-02-21 2:55 ` [PATCH for-dm-3.14-fixes 2/8] dm thin: set flag when over the metadata low watermark threshold Mike Snitzer
2014-02-21 13:56 ` Joe Thornber
2014-02-21 14:05 ` Mike Snitzer
2014-02-21 14:10 ` Mike Snitzer
2014-02-21 2:56 ` [PATCH for-dm-3.14-fixes 3/8] dm thin: set flag if metadata is out of space Mike Snitzer
2014-02-21 14:20 ` Joe Thornber
2014-02-21 14:35 ` Mike Snitzer [this message]
2014-02-21 14:44 ` Joe Thornber
2014-02-21 2:56 ` [PATCH for-dm-3.14-fixes 4/8] dm thin: error out I/O if inappropriate for it to be retried Mike Snitzer
2014-02-21 14:22 ` Joe Thornber
2014-02-21 14:48 ` Mike Snitzer
2014-02-21 2:56 ` [PATCH for-dm-3.14-fixes 5/8] dm thin: fix the error path for the thin device constructor Mike Snitzer
2014-02-21 2:56 ` [PATCH for-dm-3.14-fixes 6/8] dm thin: fix pool_preresume resize with heavy IO races Mike Snitzer
2014-02-21 14:27 ` Joe Thornber
2014-02-21 14:37 ` Mike Snitzer
2014-02-21 14:47 ` Joe Thornber
2014-02-21 2:56 ` [PATCH for-dm-3.14-fixes 7/8] dm thin: ensure user takes action to validate data and metadata consistency Mike Snitzer
2014-02-21 14:35 ` Joe Thornber
2014-02-21 2:56 ` [PATCH for-dm-3.14-fixes 8/8] dm thin: allow metadata space larger than supported to go unused Mike Snitzer
2014-02-21 14:36 ` Joe Thornber
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=20140221143540.GE4578@redhat.com \
--to=snitzer@redhat.com \
--cc=dm-devel@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.