Changeset 15520 for trunk/DataCheck/QuickLook
- Timestamp:
- 05/07/13 23:27:38 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/DataCheck/QuickLook/Step1.sh
r15388 r15520 48 48 function rsync_aux_file() 49 49 { 50 if ls $1 50 if ls $1 >/dev/null 2>&1 51 51 then 52 52 printprocesslog "INFO rsync "$1 53 53 #if ! rsync -av --stats $1 $2 54 if ! rsync -av $1 $2 54 #if ! rsync -av $1 $2 55 if ! rsync -a $1 $2 55 56 then 56 57 printprocesslog "WARN rsync of "$1" failed." 57 58 fi 59 else 60 printprocesslog "WARN "$1" missing." 58 61 fi 59 62 } 63 64 diskusage=( `df -P /raid10 | grep raid10 ` ) 65 # check if more than 700 GB are left on /loc_data 66 if [ ${diskusage[3]} -lt 800000000 ] 67 then 68 echo "WARN less than 700 left on /raid10 on node "$HOSTNAME 69 printprocesslog "WARN less than 700 left on /raid10 on node "$HOSTNAME 70 df -h /raid10 71 finish 72 fi 60 73 61 74 printprocesslog "INFO get lists of raw files on newdaq and daq" … … 73 86 makedir $rawpath 74 87 75 echo "INFO #files-daq:"${#fileslocal[@]}" #files-newdaq:"${#files[@]}" #callisto-logs:"${#callistofiles[@]}" #data-runs:"$numdataruns88 #echo "INFO #files-daq:"${#fileslocal[@]}" #files-newdaq:"${#files[@]}" #callisto-logs:"${#callistofiles[@]}" #data-runs:"$numdataruns 76 89 printprocesslog "INFO #files-daq:"${#fileslocal[@]}" #files-newdaq:"${#files[@]}" #callisto-logs:"${#callistofiles[@]}" #data-runs:"$numdataruns 77 90 … … 79 92 do 80 93 numdataruns=0 81 echo "INFO #files-daq:"${#fileslocal[@]}" #files-newdaq:"${#files[@]}" #callisto-logs:"${#callistofiles[@]}" #data-runs:"$numdataruns94 #echo "INFO #files-daq:"${#fileslocal[@]}" #files-newdaq:"${#files[@]}" #callisto-logs:"${#callistofiles[@]}" #data-runs:"$numdataruns 82 95 printprocesslog "INFO status beginning of while-loop #files-daq:"${#fileslocal[@]}" #files-newdaq:"${#files[@]}" #callisto-logs:"${#callistofiles[@]}" #data-runs:"$numdataruns 83 96 … … 89 102 printprocesslog "processing "$file 90 103 localfile=`echo $file | sed -e 's/newdaq/loc_data/'` 91 echo "processing "$file" "$localfile104 #echo "processing "$file" "$localfile 92 105 93 106 if [ "`echo $file | grep -o drs`" == "drs" ] … … 115 128 if ! ls $localfile >/dev/null 2>&1 116 129 then 117 if ! rsync -av --stats --progress --bwlimit=$bwlimit $file $localfile 130 #if ! rsync -av --stats --progress --bwlimit=$bwlimit $file $localfile 131 if ! rsync -a --bwlimit=$bwlimit $file $localfile 118 132 then 119 133 printprocesslog "ERROR something went wrong with rsync of "$file … … 196 210 #echo "numdata +1" 197 211 198 echo "cal: "$callistocount" numdat: "$numdataruns" numcallog: "${#callistofiles[@]}212 #echo "cal: "$callistocount" numdat: "$numdataruns" numcallog: "${#callistofiles[@]} 199 213 printprocesslog "INFO running callistos: "$callistocount" #data-runs: "$numdataruns" #callisto-logs: "${#callistofiles[@]} 200 214 # do not overload system in case of a lot of files to be processed … … 203 217 then 204 218 printprocesslog "INFO "$callistocount" RunCallisto.sh are running -> continue" 205 echo "INFO "$callistocount" RunCallisto.sh are running -> continue"219 #echo "INFO "$callistocount" RunCallisto.sh are running -> continue" 206 220 continue 207 221 fi … … 218 232 #`dirname $0`/RunCallisto.sh $sourcekey $seqfile & 219 233 printprocesslog "INFO starting RunCallisto.sh for "$seqfile 220 echo "INFO starting RunCallisto.sh for "$seqfile234 #echo "INFO starting RunCallisto.sh for "$seqfile 221 235 `dirname $0`/RunCallisto.sh $seqfile & 222 236 fi … … 236 250 runrow=$runrow$runnum$runtype$roi"_" 237 251 echo $runrow > $infopath/runrow.txt 238 if echo $runrow | grep -E '[0-9]{3}drs-pedestal1024_[0-9]{3}drs-gain1024_[0-9]{3}drs-pedestal1024_[0-9]{3}drs-pedestal1024_[0-9]{3}drs-time1024_[0-9]{3}pedestal300_[0-9]{3}pedestal300_' 252 if echo $runrow | grep -E '[0-9]{3}drs-pedestal1024_[0-9]{3}drs-gain1024_[0-9]{3}drs-pedestal1024_[0-9]{3}drs-pedestal1024_[0-9]{3}drs-time1024_[0-9]{3}pedestal300_[0-9]{3}pedestal300_' >/dev/null 239 253 then 240 254 runrow2=`echo $runrow | grep -E -o '[0-9]{3}drs-pedestal1024_[0-9]{3}drs-gain1024_[0-9]{3}drs-pedestal1024_[0-9]{3}drs-pedestal1024_[0-9]{3}drs-time1024_[0-9]{3}pedestal300_[0-9]{3}pedestal300_'` … … 265 279 drsfile=$run6 266 280 fi 267 if echo $runrow | grep -E '[0-9]{3}pedestal300_[0-9]{3}light-pulser-ext300_' 281 if echo $runrow | grep -E '[0-9]{3}pedestal300_[0-9]{3}light-pulser-ext300_' >/dev/null 268 282 then 269 283 echo "" > $infopath/runrow.txt … … 278 292 fileslocal=( `find $rawpath -type f | sort` ) 279 293 callistofiles=( `find $anapath/callisto -type f -name $date*-calibration.log | sort` ) 280 echo "INFO #files-daq:"${#fileslocal[@]}" #files-newdaq:"${#files[@]}" #callisto-logs:"${#callistofiles[@]}" #data-runs:"$numdataruns294 #echo "INFO #files-daq:"${#fileslocal[@]}" #files-newdaq:"${#files[@]}" #callisto-logs:"${#callistofiles[@]}" #data-runs:"$numdataruns 281 295 printprocesslog "INFO status after for-loop #files-daq:"${#fileslocal[@]}" #files-newdaq:"${#files[@]}" #callisto-logs:"${#callistofiles[@]}" #data-runs:"$numdataruns 282 296 … … 287 301 printprocesslog "INFO wait 60 seconds." 288 302 sleep 60 289 echo "sleep 60..."303 #echo "sleep 60..." 290 304 printprocesslog "INFO get new file lists for "$datepath 291 305 files=( `find $rawpathnewdaq -type f | sort` ) … … 293 307 callistofiles=( `find $anapath/callisto -type f -name $date*-calibration.log | sort` ) 294 308 fi 295 echo "INFO #files-daq:"${#fileslocal[@]}" #files-newdaq:"${#files[@]}" #callisto-logs:"${#callistofiles[@]}" #data-runs:"$numdataruns309 #echo "INFO #files-daq:"${#fileslocal[@]}" #files-newdaq:"${#files[@]}" #callisto-logs:"${#callistofiles[@]}" #data-runs:"$numdataruns 296 310 printprocesslog "INFO status after wait end of while-loop #files-daq:"${#fileslocal[@]}" #files-newdaq:"${#files[@]}" #callisto-logs:"${#callistofiles[@]}" #data-runs:"$numdataruns 297 311 done
Note:
See TracChangeset
for help on using the changeset viewer.