10566 Multiple DVA Scrubbing Fix
illumos/illumos-gate@12a8814c13fbb1d6d58616cf090ea5815dc107f9
https://github.com/illumos/illumos-gate/commit/12a8814c13fbb1d6d58616cf090ea5815dc107f9
https://www.illumos.org/issues/10566
ZoL PR_8453
Author: Tom Caputi <tcaputi@datto.com>
Date: Fri Mar 15 17:14:31 2019 -0400
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.
This update is followup on #10405
While attempting to port this update, the following ZoL updates are included:
551905dd4 vdev_mirror: kstat observables for preferred vdev
d6c6590c5 vdev_mirror: load balancing fixes
9f500936c FreeBSD r256956: Improve ZFS N-way mirror read performance byPortions contributed by: Toomas Soome <tsoome@me.com>
Portions contributed by: Jerry Jelinek <jerry.jelinek@joyent.com>
Author: Tom Caputi <tcaputi@datto.com>