zfs_mount_all_mountpoints: cleanup_all should leave pool root mounted

if pool root is not mounted, then zpool umount in next test will leave
dataset mountpoint directory around and next zfs mount -a will fail
with error: cannot mount '/testpool': directory is not empty

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Toomas Soome <tsoome@me.com>
Closes #11417
This commit is contained in:
Toomas Soome 2021-01-03 02:54:53 +02:00 committed by GitHub
parent 064c2cf40e
commit 4ba8c6b584
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -109,6 +109,8 @@ function cleanup_all
export __ZFS_POOL_RESTRICT="$TESTPOOL"
log_must zfs $unmountall
unset __ZFS_POOL_RESTRICT
# make sure we leave $TESTPOOL mounted
log_must zfs mount $TESTPOOL
for fs in ${filesystems[@]}; do
cleanup_filesystem "$TESTPOOL" "$fs"