Index: trunk/MagicSoft/Mars/datacenter/scripts/jobmanager
===================================================================
--- trunk/MagicSoft/Mars/datacenter/scripts/jobmanager	(revision 8125)
+++ trunk/MagicSoft/Mars/datacenter/scripts/jobmanager	(revision 8160)
@@ -41,4 +41,6 @@
 # endless loop
 notcount=0
+nothingtodocount=0
+nothingtodosleeptime=0
 while (( $notcount < 100 ))
 do
@@ -55,5 +57,19 @@
       then 
          prev=0
-         cont >> $jmscriptlog 2>&1
+         nothingtodocount=`expr $nothingtodocount + 1`
+         if [ $nothingtodocount -lt ${#scripts[@]} ]
+         then 
+            cont >> $jmscriptlog 2>&1
+         else
+            if [ $nothingtodosleeptime -lt $sleeptimelimit ]
+            then 
+               nothingtodosleeptime=`echo " $nothingtodocount * $sleeptime " | bc`
+            fi
+            echo "sleeping $nothingtodosleeptime" >> $jmscriptlog 2>&1
+            sleep $nothingtodosleeptime
+            cont >> $jmscriptlog 2>&1
+         fi
+      else
+         nothingtodocount=0
       fi
 
Index: trunk/MagicSoft/Mars/datacenter/scripts/setup
===================================================================
--- trunk/MagicSoft/Mars/datacenter/scripts/setup	(revision 8125)
+++ trunk/MagicSoft/Mars/datacenter/scripts/setup	(revision 8160)
@@ -62,4 +62,5 @@
 #setup for jobmanager
 sleeptime=30 #30
+sleeptimelimit=360 #360
 errorsleeptime=60 #60
 max=18 #maximum number of processes
