git: f2c88ed6ba92 - main - stress2: Added a timeout to the test
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 20 Jun 2022 12:37:24 UTC
The branch main has been updated by pho: URL: https://cgit.FreeBSD.org/src/commit/?id=f2c88ed6ba92a0074d6effbba9b0233936fbc603 commit f2c88ed6ba92a0074d6effbba9b0233936fbc603 Author: Peter Holm <pho@FreeBSD.org> AuthorDate: 2022-06-20 12:36:57 +0000 Commit: Peter Holm <pho@FreeBSD.org> CommitDate: 2022-06-20 12:36:57 +0000 stress2: Added a timeout to the test --- tools/test/stress2/misc/crossmp3.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/test/stress2/misc/crossmp3.sh b/tools/test/stress2/misc/crossmp3.sh index 0f7c01af5569..5eecb936e900 100755 --- a/tools/test/stress2/misc/crossmp3.sh +++ b/tools/test/stress2/misc/crossmp3.sh @@ -86,6 +86,7 @@ else else export runRUNTIME=20s # The test: Parallel mount and unmounts + start=`date +%s` for i in `jot 3`; do m=$1 mount /dev/md${m} ${mntpoint}$m && @@ -101,7 +102,10 @@ else umount $opt ${mntpoint}$m > /dev/null 2>&1 [ -f $CONT ] || break 2 done + [ $((`date +%s` - start)) -gt 600 ] && + { echo "Timed out"; s=1; } done rm -f $CONT fi + exit $s fi