mirror_zfs/module
Tony Hutter f40ab9e399
Fix double spares for failed vdev
It's possible for two spares to get attached to a single failed vdev.
This happens when you have a failed disk that is spared, and then you
replace the failed disk with a new disk, but during the resilver
the new disk fails, and ZED kicks in a spare for the failed new
disk.  This commit checks for that condition and disallows it.

Reviewed-by: Akash B <akash-b@hpe.com>
Reviewed-by: Ameer Hamza <ahamza@ixsystems.com>
Reviewed-by: Alexander Motin <mav@FreeBSD.org>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Tony Hutter <hutter2@llnl.gov>
Closes: #16547
Closes: #17231
2025-05-02 09:03:11 -07:00
..
avl SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
icp SPDX: license tags: LicenseRef-OpenZFS-ThirdParty-PublicDomain 2025-03-13 17:57:31 -07:00
lua SPDX: license tags: MIT 2025-03-13 17:56:54 -07:00
nvpair nvlist: Add nvlist_snprintf() and zfs_dbgmsg_nvlist() 2025-04-18 09:22:16 -04:00
os cred: properly pass and test creds on other threads (#17273) 2025-04-29 16:27:48 -07:00
unicode SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
zcommon GCC 15: Fix unterminated-string-initialization (#17244) 2025-04-16 09:33:29 -07:00
zfs Fix double spares for failed vdev 2025-05-02 09:03:11 -07:00
zstd SPDX: license tags: BSD-3-Clause OR GPL-2.0-only 2025-03-13 17:57:17 -07:00
.gitignore FreeBSD: Ignore symlink to i386 includes 2022-08-02 16:34:23 -07:00
Kbuild.in nvlist: Add nvlist_snprintf() and zfs_dbgmsg_nvlist() 2025-04-18 09:22:16 -04:00
Makefile.bsd freebsd: unbreak module/Makefile.bsd build on 15-CURRENT-arm64 2025-04-05 19:43:41 -04:00
Makefile.in Fix "make install" with DESTDIR set (#16995) 2025-02-07 16:38:58 -08:00