diff options
author | Mike Snitzer | 2015-07-15 16:52:04 -0400 |
---|---|---|
committer | Mike Snitzer | 2015-07-16 10:23:49 -0400 |
commit | bcc696fac11fe13e59dda5aaec6322a25b7c9a3a (patch) | |
tree | 956a9236835e48e108c0547eca1da8b0e8a1e2e9 /include | |
parent | b06075a98d595b761881fb2d7b8a557ea2f8b7ac (diff) |
dm thin: stay in out-of-data-space mode once no_space_timeout expires
This fixes an issue where running out of data space would cause the
thin-pool's metadata to become read-only. There was no reason to make
metadata read-only -- calling set_pool_mode() with PM_READ_ONLY was a
misguided way to error all queued and future write IOs. We can
accomplish the same by degrading from PM_OUT_OF_DATA_SPACE to
PM_OUT_OF_DATA_SPACE with error_if_no_space enabled.
Otherwise, the use of PM_READ_ONLY could cause a race where commit() was
started before the PM_READ_ONLY transition but dm_pool_commit_metadata()
would go on to fail because the block manager had transitioned to
read-only. The return of -EPERM from dm_pool_commit_metadata(), due to
attempting to commit while in read-only mode, caused the thin-pool to
set 'needs_check' because a metadata_operation_failed(). This needless
cascade of failures makes life for users more difficult than needed.
Reported-by: Vivek Goyal <vgoyal@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions