diff options
author | Tom Caputi <[email protected]> | 2019-03-15 17:14:31 -0400 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2019-03-15 14:14:31 -0700 |
commit | ab7615d92c9bf4bdbbc6a675724b763d16f05280 (patch) | |
tree | 4a61231e1be8887feb8cf3ccdae070a016cc45b7 /include/sys/zfs_ioctl.h | |
parent | 2bbec1c910a24bf61c6f41e0762e50face4b8907 (diff) |
Multiple DVA Scrubbing Fix
Currently, there is an issue in the sequential scrub code which
prevents self healing from working in some cases. The scrub code
will split up all DVA copies of a bp and issue each of them
separately. The problem is that, since each of the DVAs is no
longer associated with the others, the self healing code doesn't
have the opportunity to repair problems that show up in one of the
DVAs with the data from the others.
This patch fixes this issue by ensuring that all IOs issued by the
sequential scrub code include all DVAs. Initially, only the first
DVA of each is attempted. If an issue arises, the IO is retried
with all available copies, giving the self healing code a chance
to correct the issue.
To test this change, this patch also adds the ability for zinject
to specify individual DVAs to inject read errors into. We then
add a new test case that utilizes this functionality to ensure
scrubs and self-healing reads can handle and transparently fix
issues with individual copies of blocks.
Reviewed-by: Brian Behlendorf <[email protected]>
Reviewed-by: Matt Ahrens <[email protected]>
Signed-off-by: Tom Caputi <[email protected]>
Closes #8453
Diffstat (limited to 'include/sys/zfs_ioctl.h')
-rw-r--r-- | include/sys/zfs_ioctl.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/sys/zfs_ioctl.h b/include/sys/zfs_ioctl.h index f8c65f581..bb5b48c91 100644 --- a/include/sys/zfs_ioctl.h +++ b/include/sys/zfs_ioctl.h @@ -367,7 +367,7 @@ typedef struct zinject_record { uint64_t zi_timer; uint64_t zi_nlanes; uint32_t zi_cmd; - uint32_t zi_pad; + uint32_t zi_dvas; } zinject_record_t; #define ZINJECT_NULL 0x1 @@ -386,6 +386,8 @@ typedef struct zinject_record { #define ZI_PERCENTAGE_MIN 4294UL #define ZI_PERCENTAGE_MAX UINT32_MAX +#define ZI_NO_DVA (-1) + typedef enum zinject_type { ZINJECT_UNINITIALIZED, ZINJECT_DATA_FAULT, |