ZTS: Retry export/destroy when busy in zpool_import_012

It can take a moment for the NFS server to give up the mountpoint
after unsharing a filesystem.

Use log_must_busy to retry export/destroy a few times after switching
off sharenfs.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Igor Kozhukhov <igor@dilos.org>
Reviewed-by: George Melikov <mail@gmelikov.ru>
Signed-off-by: Ryan Moeller <ryan@iXsystems.com>
Closes #10380
This commit is contained in:
Ryan Moeller 2020-05-27 20:18:06 -04:00 committed by GitHub
parent 70a5fc0530
commit 4f8b2356cc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -147,9 +147,9 @@ for option in "" "-Df"; do
while ((guid_bit <= 1)); do
typeset guid_flag="pool name"
if [[ -z $option ]]; then
log_must zpool export $pool
log_must_busy zpool export $pool
else
log_must zpool destroy $pool
log_must_busy zpool destroy $pool
fi
typeset target=$pool