Skip to content

Commit

Permalink
ZTS: Fix zfs_mount.kshlib cleanup
Browse files Browse the repository at this point in the history
Update cleanup_filesystem to use destroy_dataset when performing
cleanup.  This ensures the destroy is retried if the pool is busy
preventing occasional failures.

Reviewed-by: George Melikov <[email protected]>
Reviewed-by: Giuseppe Di Natale <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes openzfs#10358
  • Loading branch information
behlendorf authored May 24, 2020
1 parent fb82226 commit c946d5a
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ function cleanup_filesystem #pool #fs

if datasetexists "$pool/$fs" ; then
mtpt=$(get_prop mountpoint "$pool/$fs")
log_must zfs destroy -r $pool/$fs
destroy_dataset "$pool/$fs" "-r"

[[ -d $mtpt ]] && \
log_must rm -rf $mtpt
Expand Down

0 comments on commit c946d5a

Please sign in to comment.