_cleanup()
{
cd /
- umount $SCRATCH_MNT 2>/dev/null
+ _scratch_unmount 2>/dev/null
rm -f $tmp.*
}
trap "_cleanup; exit \$status" 0 1 2 3 15
killall -q $FSSTRESS_PROG
wait
sync
-umount $SCRATCH_MNT
+_scratch_unmount
# now mount again, run the load again, this time with a shutdown.
_scratch_mount
# for some reason fsstress processes manage to live on beyond the wait?
sleep 5
-umount $SCRATCH_MNT
+_scratch_unmount
# now recover, check the filesystem for consistency
_scratch_mount
-umount $SCRATCH_MNT
+_scratch_unmount
_check_scratch_fs
# now clean up.
rm -rf $d > /dev/null 2>&1 &
done
wait
-umount $SCRATCH_MNT
+_scratch_unmount
echo "No output is good. Failures are loud."