ZTS: Restore some delays in online_offline tests

After more CI runs and code reading after #17259 I've found that
online starts resilver via async mechanism, which does not provide
wait primitives at this time.  Restore some delays to restore CI
until this is properly fixed.

Signed-off-by:	Alexander Motin <mav@FreeBSD.org>
Sponsored by:	iXsystems, Inc.
This commit is contained in:
Alexander Motin 2025-04-25 12:21:02 -04:00 committed by Tony Hutter
parent f86d9af16b
commit f85c96edf7
2 changed files with 5 additions and 1 deletions

View File

@ -59,6 +59,7 @@ function cleanup
log_must zpool online $TESTPOOL $disk
log_must check_state $TESTPOOL $disk "online"
done
sleep 1 # Delay for resilver to start
log_must zpool wait -t resilver $TESTPOOL
[[ -e $TESTDIR ]] && log_must rm -rf $TESTDIR/*
@ -77,7 +78,7 @@ for disk in $DISKLIST; do
log_must zpool online $TESTPOOL $disk
log_must check_state $TESTPOOL $disk "online"
sleep 1 # Delay for resilver to start
log_must zpool wait -t resilver $TESTPOOL
done

View File

@ -60,6 +60,7 @@ function cleanup
log_must zpool online $TESTPOOL $disk
log_must check_state $TESTPOOL $disk "online"
done
sleep 1 # Delay for resilver to start
log_must zpool wait -t resilver $TESTPOOL
[[ -e $TESTDIR ]] && log_must rm -rf $TESTDIR/*
@ -89,6 +90,7 @@ while [[ $i -lt ${#disks[*]} ]]; do
log_must zpool online $TESTPOOL ${disks[$i]}
check_state $TESTPOOL ${disks[$i]} "online" || \
log_fail "Failed to set ${disks[$i]} online"
sleep 1 # Delay for resilver to start
log_must zpool wait -t resilver $TESTPOOL
log_must zpool clear $TESTPOOL
while [[ $j -lt ${#disks[*]} ]]; do
@ -121,6 +123,7 @@ while [[ $i -lt ${#disks[*]} ]]; do
log_must zpool online $TESTPOOL ${disks[$i]}
check_state $TESTPOOL ${disks[$i]} "online" || \
log_fail "Failed to set ${disks[$i]} online"
sleep 1 # Delay for resilver to start
log_must zpool wait -t resilver $TESTPOOL
log_must zpool clear $TESTPOOL
fi