From 49783ff910cb46b9ec88b55c733a19d7874622ee Mon Sep 17 00:00:00 2001 From: Marcel Poul Date: Tue, 5 Feb 2013 13:40:27 +0000 Subject: [PATCH] need to get unused port --- org.glite.testsuites.ctb/CANL-C/tests/canl-test-ocsp.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/org.glite.testsuites.ctb/CANL-C/tests/canl-test-ocsp.sh b/org.glite.testsuites.ctb/CANL-C/tests/canl-test-ocsp.sh index b74df4f..c83408e 100755 --- a/org.glite.testsuites.ctb/CANL-C/tests/canl-test-ocsp.sh +++ b/org.glite.testsuites.ctb/CANL-C/tests/canl-test-ocsp.sh @@ -127,6 +127,15 @@ else test_failed fi +nu_port=11112 +max_port=11190 +${SYS_LSOF} -i :${nu_port} +while [ $? -eq 0 -a ${nu_port} -lt ${max_port} ] +do + nu_port=$((nu_port+1)) + ${SYS_LSOF} -i :${nu_port} +done + printf "Starting canl sample server \n" ${EMI_CANL_SERVER} -k /etc/grid-security/hostkey.pem \ -c /etc/grid-security/hostcert.pem -p "${nu_port}" & -- 1.8.2.3