Changeset 7471
- Timestamp:
- 02/01/06 18:04:43 (19 years ago)
- Location:
- trunk/MagicSoft/Mars
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/Changelog
r7468 r7471 18 18 19 19 -*-*- END OF LINE -*-*- 20 2006/02/01 Daniel Hoehne 21 22 * datacenter/scripts/buildsequenceentries, checkfilesforsequenceavail, 23 checkstardone, correcttime, dodatacheck, doexclusions, fillcallisto, 24 fillganymed, fillstar, writesequencefiles: 25 - adapted usage of function setstatus 26 27 28 20 29 2006/01/31 Daniela Dorner 21 30 -
trunk/MagicSoft/Mars/datacenter/scripts/buildsequenceentries
r7465 r7471 103 103 echo "building sequence entries for date $date..." >> $scriptlog 2>&1 104 104 year2=`echo $date | cut -c 1-4` 105 var1=$year2 106 var2=$date 105 107 buildsequentriespath=$logpath/$program/$year2 106 108 makedir $buildsequentriespath >> $scriptlog 2>&1 109 110 echo "run $program..." >> $scriptlog 2>&1 111 setstatus "start" >> $scriptlog 2>&1 107 112 108 113 check1=`root -q -b $macrospath/buildsequenceentries.C+\("\"$date\""\,"\"$datapath\""\,"\"$sequpath\""\,kFALSE\) | tee $buildsequentriespath/buildsequenceentries-$date.log | grep int | sed -e 's/(int)//'` 109 114 110 115 case $check1 in 111 1) echo "check1=$check1 -> everything ok -> setting status for $date..." >> $scriptlog 2>&1 112 statustime="Now()" 113 failed="NULL" 114 starttime="NULL" 115 failedtime="NULL" 116 var1=$year2 117 var2=$date 118 setstatus 119 ;; 120 *) echo "check1=$check1 -> ERROR - $program.C failed for $date -> step has to be repeated" >> $scriptlog 2>&1;; 116 1) echo "check1=$check1 -> everything ok -> setting status for $date..." >> $scriptlog 2>&1;; 117 *) echo "check1=$check1 -> ERROR - $program.C failed for $date -> step has to be repeated" >> $scriptlog 2>&1 118 com="building of sequences for date $date failed" 119 check=$check1 120 ;; 121 121 esac 122 123 echo "inserting the status for $program for date $date into the db" >> $scriptlog 2>&1 124 setstatus "stop" >> $scriptlog 2>&1 122 125 done 123 126 -
trunk/MagicSoft/Mars/datacenter/scripts/checkfilesforsequenceavail
r7465 r7471 103 103 no=`printf %08d $sequence | cut -c 0-4` 104 104 no2=`printf %08d $sequence` 105 var1=$no 106 var2=$no2 105 107 outpath=$logpath/$program/$no 106 108 echo "outpath: "$outpath >> $scriptlog 2>&1 … … 109 111 sequencefile=$sequpath/$no/sequence$no2.txt 110 112 113 echo "run $program..." >> $scriptlog 2>&1 114 setstatus "start" >> $scriptlog 2>&1 115 111 116 check1=`root -q -b $macrospath/checkfileavail.C+\(\""$sequencefile\""\) | tee $outpath/checkfileavail-$sequence.log | grep int | sed -e 's/(int)//'` 112 117 113 118 case $check1 in 114 1) echo "check1=$check1 -> everything ok -> setting status..." >> $scriptlog 2>&1 115 statustime="Now()" 116 failed="NULL" 117 starttime="NULL" 118 failedtime="NULL" 119 var1=$no 120 var2=$sequence 121 setstatus 122 ;; 123 *) echo "check1=$check1 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1 ;; 119 1) echo "check1=$check1 -> everything ok -> setting status..." >> $scriptlog 2>&1 ;; 120 *) echo "check1=$check1 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1 121 com="checking availability of files for sequence $sequence failed" 122 check=$check1 123 ;; 124 124 esac 125 126 echo "inserting the status for $program for sequence $sequence into the db" >> $scriptlog 2>&1 127 setstatus "stop" >> $scriptlog 2>&1 125 128 done 126 129 -
trunk/MagicSoft/Mars/datacenter/scripts/checkstardone
r7465 r7471 100 100 do 101 101 no=`printf %08d $dataset | cut -c 0-5` 102 var1=$no 103 var2=$dataset 102 104 echo "checking files for dataset $dataset..." >> $scriptlog 2>&1 103 105 datasetfile=$datasetpath/$no/dataset`printf %08d $dataset`.txt … … 117 119 makedir $outpath >> $scriptlog 2>&1 118 120 121 echo "run $program..." >> $scriptlog 2>&1 122 setstatus "start" >> $scriptlog 2>&1 123 119 124 for sequence in ${sequences[@]} 120 125 do 126 121 127 check1=`root -q -b $macrospath/checkstardone.C+\(\""$sequence\""\) | tee $outpath/checkstardone-$sequence.log | grep int | sed -e 's/(int)//'` 122 128 … … 125 131 *) echo "check1=$check1 -> ERROR " >> $scriptlog 2>&1 126 132 echo "starfiles not available for sequence -> continue" >> $scriptlog 2>&1 127 continue 2 133 com="starfile missing for sequence $sequence" 134 check=$check1 135 break 128 136 ;; 129 137 esac 130 138 done 131 139 132 statustime="Now()" 133 failed="NULL" 134 starttime="NULL" 135 failedtime="NULL" 136 var1=$no 137 var2=$dataset 138 setstatus 140 echo "inserting the status for $program for dataset $dataset into the db" >> $scriptlog 2>&1 141 setstatus "stop" >> $scriptlog 2>&1 139 142 done 140 143 -
trunk/MagicSoft/Mars/datacenter/scripts/correcttime
r7465 r7471 80 80 for run in ${runs[@]} 81 81 do 82 no=`printf %08d $run | cut -c 1-5` 83 var1=$no 84 var2=$run 82 85 echo "getting path for run $run ... " 83 86 infile=`find $datapath/rawfiles-wrong-timing/ -name *${run}_[D,C,P,S]_*` … … 94 97 95 98 check1=0 96 echo "run $program..." 99 echo "run $program..." >> $scriptlog 2>&1 100 setstatus "start" >> $scriptlog 2>&1 101 97 102 /home/tape/MagicReadout/correct_raw_time $infile $outfile > $timecorrpath/$program-$run.log 98 103 check1=$? 99 104 100 105 case $check1 in 101 1) echo "check1=$check1 -> everything ok -> setting status..." 102 no=`printf %08d $run | cut -c 1-5` 103 statustime="Now()" 104 failed="NULL" 105 starttime="NULL" 106 failedtime="NULL" 107 var1=$no 108 var2=$run 109 setstatus 110 ;; 111 *) echo "check1=$check1 -> ERROR -> step has to be repeated";; 106 1) echo "check1=$check1 -> everything ok -> setting status..." >> $scriptlog 2>&1 ;; 107 *) echo "check1=$check1 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1 ;; 108 com="time correction for run $run failed" 109 check=$check1 110 ;; 112 111 esac 112 echo "inserting the status for $program for run $run into the db" >> $scriptlog 2>&1 113 setstatus "stop" >> $scriptlog 2>&1 113 114 done 114 115 -
trunk/MagicSoft/Mars/datacenter/scripts/dodatacheck
r7465 r7471 143 143 for run in ${runs[@]} 144 144 do 145 date146 145 echo "do $program for run "$run >> $scriptlog 2>&1 147 146 no=`printf %08d $run | cut -c 0-2` 148 147 no2=`printf %08d $run` 148 var1=$date 149 var2=$no2 149 150 rawfile=`find /magic/data/rawfiles/ -name *${run}_[D,P,C,S]_*_E.raw` 150 151 echo "rawfile: "$rawfile >> $scriptlog 2>&1 … … 161 162 162 163 echo "doing filldotraw..." >> $scriptlog 2>&1 164 setstatus "start" >> $scriptlog 2>&1 165 163 166 check1=`root -q -b $macrospath/filldotraw.C+\("\"$rawfile\""\,kFALSE\) | tee $filldotrawlogfile | grep int | sed -e 's/.*(int)//'` 164 167 … … 167 170 ;; 168 171 *) echo "check1=$check1 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1 169 continue;; 172 com="filldotraw for run $run failed" 173 check=$check1 174 setstatus "stop" >> $scriptlog 2>&1 175 continue ;; 170 176 esac 171 177 … … 189 195 ;; 190 196 *) echo "check2=$check2 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1 197 com="sinope for run $run failed" 198 check=$check2 199 setstatus "stop" >> $scriptlog 2>&1 191 200 continue 2;; 192 201 esac … … 206 215 ;; 207 216 *) echo "check3=$check3 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1 217 com="fillsinope for run $run failed" 218 check=$check3 219 setstatus "stop" >> $scriptlog 2>&1 208 220 continue;; 209 221 esac … … 222 234 ;; 223 235 *) echo "check5=$check5 -> ERROR -> step could not be resetted -> repeat step " >> $scriptlog 2>&1 236 com="reset status for fExclusionsDone for date $date2 failed" 237 check=$check5 238 setstatus "stop" >> $scriptlog 2>&1 224 239 continue;; 225 240 esac -
trunk/MagicSoft/Mars/datacenter/scripts/doexclusions
r7465 r7471 103 103 echo "do exclusions for date "$date >> $scriptlog 2>&1 104 104 year2=`echo $date | cut -c 1-4` 105 var1=$year2 106 var2=$date 105 107 doexclusionspath=$logpath/$program/$year2 106 108 makedir $doexclusionspath >> $scriptlog 2>&1 109 110 echo "run $program..." >> $scriptlog 2>&1 111 setstatus "start" >> $scriptlog 2>&1 107 112 108 113 check1=`root -q -b $macrospath/doexclusions.C+\("\"$date\""\) | tee $doexclusionspath/doexclusions-$date.log | grep int | sed -e 's/(int)//'` 109 114 110 115 case $check1 in 111 1) echo "check1=$check1 -> everything ok -> setting status..." >> $scriptlog 2>&1 112 statustime="Now()" 113 failed="NULL" 114 starttime="NULL" 115 failedtime="NULL" 116 var1=$year2 117 var2=$date 118 setstatus 119 ;; 116 1) echo "check1=$check1 -> everything ok -> setting status..." >> $scriptlog 2>&1 ;; 120 117 *) echo "check1=$check1 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1 ;; 118 com="doing exclusions for date $date failed" 119 check=$check1 120 ;; 121 121 esac 122 echo "inserting the status for $program for date $date into the db" >> $scriptlog 2>&1 123 setstatus "stop" >> $scriptlog 2>&1 122 124 done 123 125 -
trunk/MagicSoft/Mars/datacenter/scripts/fillcallisto
r7465 r7471 104 104 no=`printf %08d $sequence | cut -c 0-4` 105 105 no2=`printf %08d $sequence` 106 var1=$no 107 var2=$no2 106 108 path="$datapath/callisto/$no/$no2" 107 109 signalfile=$path/signal$no2.root … … 114 116 115 117 echo "run $program for sequence $sequence" >> $scriptlog 2>&1 118 setstatus "start" >> $scriptlog 2>&1 116 119 echo "run fillcalib..." >> $scriptlog 2>&1 120 117 121 check1=`root -q -b $macrospath/fillcalib.C+\("\"$calibfile\""\,kFALSE\) | tee $fillcaliblog | grep int | sed -e 's/(int)//'` 118 122 119 123 case $check1 in 120 1) echo "check1=$check1 -> everything ok -> run fillsignal " >> $scriptlog 2>&1 ;;124 1) echo "check1=$check1 -> everything ok -> run fillsignal " >> $scriptlog 2>&1 ;; 121 125 *) echo "check1=$check1 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1 122 continue;; 126 com="fillcalib for sequence $sequence failed" 127 check=$check1 128 setstatus "stop" >> $scriptlog 2>&1 129 continue ;; 123 130 esac 124 131 125 132 check2=`root -q -b $macrospath/fillsignal.C+\("\"$signalfile\""\,kFALSE\) | tee $fillsignallog | grep int | sed -e 's/(int)//'` 126 133 case $check2 in 127 1) echo "check2=$check2 -> everything ok " >> $scriptlog 2>&1 128 echo "-> inserting the status for $program for sequence $sequence into the db" >> $scriptlog 2>&1 129 statustime="Now()" 130 failed="NULL" 131 starttime="NULL" 132 failedtime="NULL" 133 var1=$no 134 var2=$sequence 135 setstatus 136 ;; 137 *) echo "check2=$check2 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1;; 134 1) echo "check2=$check2 -> everything ok " >> $scriptlog 2>&1 ;; 135 *) echo "check2=$check2 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1 136 com="fillsignal for sequencec $sequence failed" 137 check=$check2 138 ;; 138 139 esac 140 echo "inserting the status for $program for sequence $sequence into the db" >> $scriptlog 2>&1 141 setstatus "stop" >> $scriptlog 2>&1 139 142 done 140 143 -
trunk/MagicSoft/Mars/datacenter/scripts/fillganymed
r7465 r7471 104 104 no=`printf %08d $dataset | cut -c 0-5` 105 105 no2=`printf %08d $dataset` 106 var1=$no 107 var2=$no2 106 108 path="$datapath/ganymed/$no/$no2" 107 109 ganymedfile=$path/ganymed$no2.root … … 112 114 113 115 echo "run $program for dataset $dataset" >> $scriptlog 2>&1 116 setstatus "start" >> $scriptlog 2>&1 117 114 118 check2=`root -q -b $macrospath/fillganymed.C+\("\"$ganymedfile\""\,kFALSE\) | tee $fillganymedlog | grep int | sed -e 's/(int)//'` 115 119 case $check2 in 116 1) echo "check2=$check2 -> everything ok " >> $scriptlog 2>&1 117 echo "-> inserting the status for $program for dataset $dataset into the db" >> $scriptlog 2>&1 118 statustime="Now()" 119 failed="NULL" 120 starttime="NULL" 121 failedtime="NULL" 122 var1=$no 123 var2=$no2 124 setstatus 125 ;; 126 *) echo "check2=$check2 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1;; 120 1) echo "check2=$check2 -> everything ok " >> $scriptlog 2>&1 ;; 121 *) echo "check2=$check2 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1 122 com="fillganymed for dataset $dataset failed" 123 check=$check2 124 ;; 127 125 esac 126 echo "inserting the status for $program for dataset $dataset into the db" >> $scriptlog 2>&1 127 setstatus "stop" >> scriptlog 2>&1 128 128 done 129 129 -
trunk/MagicSoft/Mars/datacenter/scripts/fillstar
r7465 r7471 104 104 no=`printf %08d $sequence | cut -c 0-4` 105 105 no2=`printf %08d $sequence` 106 var1=$no 107 var2=$no2 106 108 path="$datapath/star/$no/$no2" 107 109 starfile=$path/star$no2.root … … 112 114 113 115 echo "run $program for sequence $sequence" >> $scriptlog 2>&1 116 setstatus "start" >> $scriptlog 2>&1 117 114 118 check2=`root -q -b $macrospath/fillstar.C+\("\"$starfile\""\,kFALSE\) | tee $fillstarlog | grep int | sed -e 's/(int)//'` 115 119 case $check2 in 116 1) echo "check2=$check2 -> everything ok " >> $scriptlog 2>&1 117 echo "-> inserting the status for $program for sequence $sequence into the db" >> $scriptlog 2>&1 118 statustime="Now()" 119 failed="NULL" 120 starttime="NULL" 121 failedtime="NULL" 122 var1=$no 123 var2=$no2 124 setstatus 125 ;; 120 1) echo "check2=$check2 -> everything ok " >> $scriptlog 2>&1 ;; 126 121 *) echo "check2=$check2 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1;; 122 com="fillstar for sequence $sequence failed" 123 check=$check2 124 ;; 127 125 esac 126 echo "inserting the status for $program for sequence $sequence into the db" >> $scriptlog 2>&1 127 setstatus "stop" >> $scriptlog 2>&1 128 128 done 129 129 -
trunk/MagicSoft/Mars/datacenter/scripts/sourcefile
r7470 r7471 79 79 echo " failedtime=$failedtime" 80 80 echo "-- check: -$check-" 81 ech82 81 echo "" 83 82 } -
trunk/MagicSoft/Mars/datacenter/scripts/writesequencefiles
r7465 r7471 104 104 no=`printf %08d $sequence | cut -c 0-4` 105 105 no2=`printf %08d $sequence` 106 var1=$no 107 var2=$no2 106 108 sequencepath=$sequpath/$no 107 109 makedir $sequencepath >> $scriptlog 2>&1 … … 112 114 113 115 echo "write sequencefile for sequence $sequence" >> $scriptlog 2>&1 116 setstatus "start" >> $scriptlog 2>&1 117 114 118 check2=`root -q -b $macrospath/writesequencefile.C+\($sequence\,"\"$sequpath\""\) | tee $writesequencefilelogpath/writesequencefile-$no2.log | grep int | sed -e 's/(int)//'` 115 119 case $check2 in 116 1) echo "check2=$check2 -> everything ok " >> $scriptlog 2>&1 117 echo "-> inserting the status for $program for sequence $sequence into the db" >> $scriptlog 2>&1 118 statustime="Now()" 119 failed="NULL" 120 starttime="NULL" 121 failedtime="NULL" 122 var1=$no 123 var2=$no2 124 setstatus 125 ;; 120 1) echo "check2=$check2 -> everything ok " >> $scriptlog 2>&1 ;; 126 121 *) echo "check2=$check2 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1;; 122 com="writing of sequencefile for sequence $sequence failed" 123 check=$check2 124 ;; 127 125 esac 126 echo "inserting the status for $program for sequence $sequence into the db" >> $scriptlog 2>&1 127 setstatus "stop" >> $scriptlog 2>&1 128 128 done 129 129
Note:
See TracChangeset
for help on using the changeset viewer.