diff --git a/SubSystems/Online_Cobalt/test/tstartBGL.run b/SubSystems/Online_Cobalt/test/tstartBGL.run
index 800d5ddf1ce40e3ef64363c4cca5fea5357d2ff4..a50c54de596cfd12ff72d4db3611852400fba996 100755
--- a/SubSystems/Online_Cobalt/test/tstartBGL.run
+++ b/SubSystems/Online_Cobalt/test/tstartBGL.run
@@ -67,8 +67,13 @@ for cluster in CEP4 DRAGNET; do  # all in cobalt_functions.sh as used by runObse
 
   # 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.
-  # Used 'nice -n 5' to dramatically increase the chance that we check before the pid file is removed again.
-  sleep 1
+  # PID file must appear within 20s
+  TIMEOUT=20
+  while [ "$TIMEOUT" -gt 0 -a ! -e $LOFARROOT/var/run/rtcp-1000.pid ]
+  do
+    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 be gone after 20s