Changeset 18723 for trunk/DataCheck/Transfer
- Timestamp:
- 01/08/17 17:21:53 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/DataCheck/Transfer/CheckTransfer.sh
r18700 r18723 101 101 if grep "EVERYTHING" $logfile >/dev/null 2>&1 102 102 then 103 echo " "$date" has been checked already and is fine. Please check logfile "$logfile 104 echo " "$date" has been checked already and is fine. Please check logfile "$logfile >> $logfile2 2>&1 103 if grep "fails" $logfile 2>/dev/null | grep "INFO" >/dev/null 2>&1 104 then 105 echo " "$date" has been checked already. Please check logfile "$logfile 106 echo " "$date" has been checked already. Please check logfile "$logfile >> $logfile2 2>&1 107 else 108 echo " "$date" has been checked already and is fine. Please check logfile "$logfile 109 echo " "$date" has been checked already and is fine. Please check logfile "$logfile >> $logfile2 2>&1 110 fi 105 111 sendemail="yes" 106 112 continue … … 176 182 queryjoin="LEFT JOIN RunInfo USING(fNight,fRunID) " 177 183 querywhere="WHERE fNight="$date2" AND NOT ISNULL(fStartTime) AND NOT ISNULL(fStopTime) AND ISNULL(fReturnCode)" 184 querywhere2="WHERE fNight="$date2" AND NOT ISNULL(fStartTime) AND NOT ISNULL(fStopTime) AND (ISNULL(fReturnCode) OR fReturnCode=0)" 178 185 numruns=`sendquery` 179 186 if [ "$numruns" == "" ] … … 192 199 then 193 200 numisdc=0 201 fi 202 query=$querystart"RawFileAvailISDCStatus "$queryjoin" "$querywhere2 203 numisdc2=`sendquery` 204 if [ "$numisdc2" == "" ] 205 then 206 numisdc2=0 194 207 fi 195 208 query=$querystart"RawFileAvailWueStatus "$queryjoin" "$querywhere … … 225 238 printprocesslog " rsynced "$numrsynced 226 239 printprocesslog " isdc "$numisdc 240 printprocesslog " isdc "$numisdc2" (incl fails folder)" 227 241 printprocesslog " wue "$numwue 228 242 #printprocesslog " phido "$numphido … … 247 261 echo " rsynced "$numrsynced >> $logfile 2>&1 248 262 echo " isdc "$numisdc >> $logfile 2>&1 263 echo " isdc "$numisdc2" (incl fails folder)" >> $logfile 2>&1 249 264 echo " wue "$numwue >> $logfile 2>&1 250 265 #echo " phido "$numphido >> $logfile 2>&1 … … 500 515 printprocesslog "WARN number of ingested files in archive ("$numisdc") not equal to number of runs ("$numruns") for "$date" [DB]" 501 516 echo "WARN number of ingested files in archive ("$numisdc") not equal to number of runs ("$numruns") for "$date" [DB]" >> $logfile 2>&1 502 numpb=`echo " $numpb + 1 " | bc -l ` 503 result3=$result3"1" 517 numisdctotal=`echo " $numisdc + $numisdc2 " | bc -l ` 518 if ! [ $numruns -eq $numisdc2 ] 519 then 520 printprocesslog "WARN number of ingested files in archive incl fails folder ("$numisdc2") not equal to number of runs ("$numruns") for "$date" [DB]" 521 echo "WARN number of ingested files in archive incl fails folder ("$numisdc2") not equal to number of runs ("$numruns") for "$date" [DB]" >> $logfile 2>&1 522 numpb=`echo " $numpb + 1 " | bc -l ` 523 result3=$result3"1" 524 else 525 numok=`echo " $numok + 1 " | bc -l ` 526 result3=$result3"0" 527 fi 504 528 else 505 529 numok=`echo " $numok + 1 " | bc -l ` … … 540 564 printprocesslog "number of files does not yet agree in db ("$result3") -> do no further checking." 541 565 echo "" >> $logfile 2>&1 542 echo "number of files does not yet agree in all sites ("$result1") -> do no further checking." >> $logfile 2>&1566 echo "number of files does not yet agree in db ("$result3") -> do no further checking." >> $logfile 2>&1 543 567 echo "" >> $logfile 2>&1 544 568 # print to console 545 echo "SUMMARY for "$date 546 echo "----------------------- "547 echo " number of files does not yet agree in all sites: "${newdaq[0]}" (newdaq) "${daq[0]}" (daq) "${zip[0]}" (data) "${dl00[0]}" (dl) "${wue[0]}" (wue) "${archive[0]}" (arch) "${fails[0]}" (fails) "${qla[@]}" (qla) "$numdatruns" (datruns) "569 echo "SUMMARY for "$date" (DB):" 570 echo "-----------------------------" 571 echo " number of runs does not yet agree in DB: "${newdaq[0]}" (newdaq) "$numruns}" (RunInfo) "$numrsynced" (RsyncedToISDC) "$numisdc" (AvailISDC) "$numwue" (AvailWue) " 548 572 echo " "$date" is not yet transfered completely. Please check the logfile "$logfile 549 573 # print to single logfile 550 echo "SUMMARY for "$date >> $logfile 2>&1551 echo "----------------------- " >> $logfile 2>&1552 echo " number of files does not yet agree in all sites: "${newdaq[0]}" (newdaq) "${daq[0]}" (daq) "${zip[0]}" (data) "${dl00[0]}" (dl) "${wue[0]}" (wue) "${archive[0]}" (arch) "${fails[0]}" (fails) "${qla[@]}" (qla) "$numdatruns" (datruns) " >> $logfile 2>&1574 echo "SUMMARY for "$date" (DB):" >> $logfile 2>&1 575 echo "-----------------------------" >> $logfile 2>&1 576 echo " number of runs does not yet agree in DB: "${newdaq[0]}" (newdaq) "$numruns}" (RunInfo) "$numrsynced" (RsyncedToISDC) "$numisdc" (AvailISDC) "$numwue" (AvailWue) " >> $logfile 2>&1 553 577 echo " "$date" is not yet transfered completely. Please check the logfile "$logfile >> $logfile 2>&1 554 578 # print to global logfile 555 echo "SUMMARY for "$date >> $logfile2 2>&1556 echo "----------------------- " >> $logfile2 2>&1557 echo " number of files does not yet agree in all sites: "${newdaq[0]}" (newdaq) "${daq[0]}" (daq) "${zip[0]}" (data) "${dl00[0]}" (dl) "${wue[0]}" (wue) "${archive[0]}" (arch) "${fails[0]}" (fails) "${qla[@]}" (qla) "$numdatruns" (datruns) " >> $logfile2 2>&1579 echo "SUMMARY for "$date" (DB):" >> $logfile2 2>&1 580 echo "-----------------------------" >> $logfile2 2>&1 581 echo " number of runs does not yet agree in DB: "${newdaq[0]}" (newdaq) "$numruns}" (RunInfo) "$numrsynced" (RsyncedToISDC) "$numisdc" (AvailISDC) "$numwue" (AvailWue) " >> $logfile2 2>&1 558 582 echo " "$date" is not yet transfered completely. Please check the logfile "$logfile >> $logfile2 2>&1 559 583 continue … … 945 969 if ! [ $numdatruns -eq $qla ] 946 970 then 947 echo "WARN not all data runs are processed yet by the QLA. " 948 echo "WARN not all data runs are processed yet by the QLA. " >> $logfile 2>&1 949 echo "WARN not all data runs are processed yet by the QLA. " >> $logfile2 2>&1 971 echo " WARN not all data runs are processed yet by the QLA. " 972 echo " WARN not all data runs are processed yet by the QLA. " >> $logfile 2>&1 973 echo " WARN not all data runs are processed yet by the QLA. " >> $logfile2 2>&1 974 fi 975 if [ ${fails[0]} -gt 0 ] || [ $numisdc -ne $numisdc2 ] 976 then 977 echo " INFO there is "${fails[0]}" file in the fails folder. Please check. " 978 echo " INFO there is "${fails[0]}" file in the fails folder. Please check. " >> $logfile 2>&1 979 echo " INFO there is "${fails[0]}" file in the fails folder. Please check. " >> $logfile2 2>&1 950 980 fi 951 981 echo ""
Note:
See TracChangeset
for help on using the changeset viewer.