Changeset 7936 for trunk/MagicSoft/Mars/datacenter/scripts/jobmanager
- Timestamp:
- 08/25/06 13:40:49 (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/datacenter/scripts/jobmanager
r7933 r7936 36 36 37 37 echo "" >> $jmscriptlog 2>&1 38 echo `date`": starting jobmanager" >> $jmscriptlog 2>&138 echo "starting jobmanager ("`date`")" >> $jmscriptlog 2>&1 39 39 makedir $jmlogpath 40 40 makedir $listpath >> $jmscriptlog 2>&1 41 41 makedir $lockpath >> $jmscriptlog 2>&1 42 42 43 prev=$max 43 44 notcount=0 44 45 while (( $notcount < 100 )) … … 72 73 num=`echo "((( $i + 1 ) * 24 ) + ( $hour + 1 ) ) - 24 - 1 " | bc ` 73 74 pnoscript=${pnos[$num]} 75 if [ $prev -eq 0 ] 76 then 77 echo " prev=0 => resetting pnoscript [$pnoscript] to max [$max]" >> $jmscriptlog 2>&1 78 pnoscript=$max 79 fi 74 80 echo " found $queued jobs in the queue (incl. running jobs) [allowed $totalpno]" >> $jmscriptlog 2>&1 75 echo " found $queuedscript ${scripts[$i]} in the queue (incl. running jobs) [allowed $pnoscript]" >> $jmscriptlog 2>&1 76 # echo " => num=$num => pnoscript=$pnoscript (i.e. $pnoscript ${scripts[$i]} allowed)" >> $jmscriptlog 2>&1 81 echo " found $queuedscript ${scripts[$i]} in the queue (incl. running jobs [$runningscript]) [allowed $pnoscript] - not running: $stillinqueue" >> $jmscriptlog 2>&1 77 82 78 83 if [ "$queued" -gt "$totalpno" ] … … 87 92 88 93 # check if there's something to do 89 getstatus 94 getstatus >> $jmscriptlog 2>&1 95 echo " $numproc ${scripts[$i]} still do to" >> $jmscriptlog 2>&1 90 96 if [ "$numproc" = "" ] 91 97 then 98 prev=0 92 99 cont >> $jmscriptlog 2>&1 93 100 fi 94 if ! [ $numproc -gt 0 ] 95 then 96 cont >> $jmscriptlog 2>&1 97 fi 101 prev=$max 98 102 if [ $numproc -lt $stillinqueue ] 99 103 then 100 echo " numproc($numproc) -lt stillinqueue($stillinqueue)" >> $jmscriptlog 2>&1104 echo " numproc($numproc) -lt stillinqueue($stillinqueue)" >> $jmscriptlog 2>&1 101 105 cont >> $jmscriptlog 2>&1 102 106 fi … … 107 111 makedir $condordir >> $jmscriptlog 2>&1 108 112 113 echo " committing 1 ${scripts[$i]} to condor" >> $jmscriptlog 2>&1 109 114 if ! /usr/local/bin/condor_submit -a path=$scriptspath -a prog=${scripts[$i]} -a date=$date2 -a dir=$condordir $scriptspath/run.condor 2>> $jmerrorlog 110 115 then … … 114 119 sleep $errorsleeptime 115 120 fi 121 date >> $jmscriptlog 2>&1 116 122 echo "" >> $jmscriptlog 2>&1 117 123 done
Note:
See TracChangeset
for help on using the changeset viewer.