mirror of
https://github.com/opnsense/src.git
synced 2026-06-12 18:20:49 -04:00
Fix the zfsd_fault_001_pos test
Due to a regression in ZFS, a pool's status may not change to DEGRADED promptly after a vdev becomes faulted. This test is primarily concerned with vdev status, not pool status, so work around the bug by doing a "zpool reopen". Otherwise the test would time out waiting for a status change that never came. MFC to stable/14 only. https://github.com/openzfs/zfs/issues/16245 MFC after: 2 weeks Sponsored by: ConnectWise
This commit is contained in:
parent
c50c5a47a9
commit
01a1dd3218
1 changed files with 4 additions and 0 deletions
|
|
@ -78,6 +78,10 @@ for type in "raidz" "mirror"; do
|
|||
$DD if=/dev/zero bs=128k count=1 >> \
|
||||
/$TESTPOOL/$TESTFS/$TESTFILE 2> /dev/null
|
||||
$FSYNC /$TESTPOOL/$TESTFS/$TESTFILE
|
||||
# Due to a bug outside of zfsd, it may be necessary to reopen
|
||||
# the pool before it will become DEGRADED.
|
||||
# https://github.com/openzfs/zfs/issues/16245
|
||||
$ZPOOL reopen $TESTPOOL
|
||||
# Check to see if the pool is faulted yet
|
||||
$ZPOOL status $TESTPOOL | grep -q 'state: DEGRADED'
|
||||
if [ $? == 0 ]
|
||||
|
|
|
|||
Loading…
Reference in a new issue