diff options
author | Li Nan <linan122@huawei.com> | 2023-06-02 17:18:38 +0800 |
---|---|---|
committer | Song Liu <song@kernel.org> | 2023-06-13 15:25:43 -0700 |
commit | 8d355a46c1e0cea59be3ea8395409a5e6eeed946 (patch) | |
tree | 787ce85757eda10e9a33542fc655f10a0adde090 /tools/perf/scripts/python/export-to-postgresql.py | |
parent | 4d8a5754a694062f349b8bf66856561e3840c7e5 (diff) |
md/raid10: Do not add spare disk when recovery fails
In raid10_sync_request(), if data cannot be read from any disk for
recovery, it will go to 'giveup' and let 'chunks_skipped' + 1. After
multiple 'giveup', when 'chunks_skipped >= geo.raid_disks', it will
return 'max_sector', indicating that the recovery has been completed.
However, the recovery is just aborted and the data remains inconsistent.
Fix it by setting mirror->recovery_disabled, which will prevent the spare
disk from being added to this mirror. The same issue also exists during
resync, it will be fixed afterwards.
Signed-off-by: Li Nan <linan122@huawei.com>
Signed-off-by: Song Liu <song@kernel.org>
Link: https://lore.kernel.org/r/20230602091839.743798-2-linan666@huaweicloud.com
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions