svn commit: r253409 - user/pho/stress2/misc
Peter Holm
pho at FreeBSD.org
Wed Jul 17 06:11:44 UTC 2013
Author: pho
Date: Wed Jul 17 06:11:43 2013
New Revision: 253409
URL: http://svnweb.freebsd.org/changeset/base/253409
Log:
Added a fail safe test termination method.
Sponsored by: EMC / Isilon storage division
Modified:
user/pho/stress2/misc/tcp.sh
user/pho/stress2/misc/tcp2.sh
Modified: user/pho/stress2/misc/tcp.sh
==============================================================================
--- user/pho/stress2/misc/tcp.sh Wed Jul 17 04:53:53 2013 (r253408)
+++ user/pho/stress2/misc/tcp.sh Wed Jul 17 06:11:43 2013 (r253409)
@@ -44,6 +44,10 @@ n=`su $testuser -c "limits | grep maxpro
export tcpINCARNATIONS=$((n / 2 - 10))
export TESTPROGS=" ./testcases/tcp/tcp"
-su $testuser -c '(cd ..; ./testcases/run/run $TESTPROGS)'
+su $testuser -c '(cd ..; ./testcases/run/run $TESTPROGS)' &
-ps -U$testuser | sed 1d | awk '{print $1}' | xargs kill -9
+sleep $((15 * 60))
+while pkill -9 -U $testuser tcp; do
+ sleep .5
+done
+wait
Modified: user/pho/stress2/misc/tcp2.sh
==============================================================================
--- user/pho/stress2/misc/tcp2.sh Wed Jul 17 04:53:53 2013 (r253408)
+++ user/pho/stress2/misc/tcp2.sh Wed Jul 17 06:11:43 2013 (r253409)
@@ -48,6 +48,10 @@ export TESTPROGS="
./testcases/swap/swap
"
-su $testuser -c '(cd ..; ./testcases/run/run $TESTPROGS)'
+su $testuser -c '(cd ..; ./testcases/run/run $TESTPROGS)' &
-ps -U$testuser | sed 1d | awk '{print $1}' | xargs kill -9
+sleep $((15 * 60))
+while pkill -9 -U $testuser "tcp|swap"; do
+ sleep .5
+done
+wait
More information about the svn-src-user
mailing list