Skip to content

Commit

Permalink
Fix datasets held open after tests
Browse files Browse the repository at this point in the history
Fix for post-testing error:

`cannot destroy 'tmp.uwIwWzoNp4/tmp': dataset is busy`

Thanks to @nalind for the fix.

Signed-off-by: Chris Evich <[email protected]>
  • Loading branch information
cevich committed Apr 4, 2023
1 parent 1ad45ee commit 224f0b9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions contrib/cirrus/build_and_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,8 @@ case $TEST_DRIVER in
trap "zfs destroy -Rf $zpool/tmp; zpool destroy -f $zpool; rm -f $tmpfile" EXIT
zfs create $zpool/tmp
TMPDIR="/$zpool/tmp" showrun make STORAGE_DRIVER=$TEST_DRIVER local-test-integration local-test-unit
# Ensure no datasets are held open prior to `zfs destroy` trap.
kill $(lsns -J -t mnt --output-all | jq '.namespaces[]|select(.command=="sleep 1000s").pid')
;;
*)
die "Unknown/Unsupported \$TEST_DRIVER=$TEST_DRIVER (see .cirrus.yml and $(basename $0))"
Expand Down

0 comments on commit 224f0b9

Please sign in to comment.