diff --git a/SubSystems/Online_Cobalt/test/tstartBGL.run b/SubSystems/Online_Cobalt/test/tstartBGL.run index 75e8e3ca24ae45148a8de2e20f8c6305334ab0e0..9f38eb2fc70bf47b092fd0cea5389af9131838ee 100755 --- a/SubSystems/Online_Cobalt/test/tstartBGL.run +++ b/SubSystems/Online_Cobalt/test/tstartBGL.run @@ -60,26 +60,30 @@ echo " (expects success)" echo "***************************" # Add the connection information for this test echo "Cobalt.FinalMetaDataGatherer.host=localhost" >> tstartBGL.in_parset -startBGL.sh 1 2 3 tstartBGL.in_parset 1000 || error "startBGL.sh failed" - -# PID file is created by runObservation.sh, which is started in the background. Although the PID file -# is created almost immediately, we may be too fast if we check without waiting. -sleep 1 -[ -e $LOFARROOT/var/run/rtcp-1000.pid ] || error "Found no $LOFARROOT/var/run/rtcp-1000.pid" +for cluster in CEP4 DRAGNET; do # all in cobalt_functions.sh as used by runObservation.sh + echo "Testing with storageClusterName $cluster" + echo "Observation.DataProducts.Output_Correlated.storageClusterName=$cluster" >> tstartBGL.in_parset + startBGL.sh 1 2 3 tstartBGL.in_parset 1000 || error "startBGL.sh failed" -# PID file must be gone after 30s -TIMEOUT=30 -while [ "$TIMEOUT" -gt 0 -a -e $LOFARROOT/var/run/rtcp-1000.pid ] -do + # PID file is created by runObservation.sh, which is started in the background. Although the PID file + # is created almost immediately, we may be too fast if we check without waiting. sleep 1 - TIMEOUT=$((TIMEOUT - 1)) -done + [ -e $LOFARROOT/var/run/rtcp-1000.pid ] || error "Found no $LOFARROOT/var/run/rtcp-1000.pid" -# PID file must NOT be present -[ -e $LOFARROOT/var/run/rtcp-1000.pid ] && error "Found lingering $LOFARROOT/var/run/rtcp-1000.pid" + # PID file must be gone after 20s + TIMEOUT=20 + while [ "$TIMEOUT" -gt 0 -a -e $LOFARROOT/var/run/rtcp-1000.pid ] + do + sleep 1 + TIMEOUT=$((TIMEOUT - 1)) + done -# Log file must be present -[ -r $LOFARROOT/var/log/rtcp-1000.log ] || error "Cannot read $LOFARROOT/var/log/rtcp-1000.log" + # PID file must NOT be present + [ -e $LOFARROOT/var/run/rtcp-1000.pid ] && error "Found lingering $LOFARROOT/var/run/rtcp-1000.pid" + + # Log file must be present + [ -r $LOFARROOT/var/log/rtcp-1000.log ] || error "Cannot read $LOFARROOT/var/log/rtcp-1000.log" +done echo "***************************" echo "Test 6: stop a run" @@ -104,8 +108,8 @@ startBGL.sh 1 2 3 tstartBGL.in_parset 1000 || error "startBGL.sh failed" # - if stopBGL.sh malfunctions, rtcp will linger stopBGL.sh 1 1000 || error "stopBGL.sh failed" -# PID file must be gone after 30s -TIMEOUT=30 +# PID file must be gone after 20s +TIMEOUT=20 while [ "$TIMEOUT" -gt 0 -a -e $LOFARROOT/var/run/rtcp-1000.pid ] do sleep 1