Ignore:
Timestamp:
Oct 3, 2011, 10:58:41 AM (13 years ago)
Author:
campagne
Message:

avoid the link to a specif bao daq date (jec)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • BAORadio/AmasNancay/gainmaker.sh

    r529 r540  
    101101
    102102
     103#JEC 1/10/11 Use generic baodaqstatus name
    103104#get the daq current irod status
    104 tag=`${DATE} +%F`
    105 OUT1=${publicpath}/baodaqstatus-${tag}.txt
     105#tag=`${DATE} +%F`
     106#OUT1=${publicpath}/baodaqstatus-${tag}.txt
     107OUT1=${publicpath}/baodaqstatus-current.txt
    106108
    107109if [ ! -e ${OUT1}  -o ! -r ${OUT1} ]; then
    108     $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    109     $RM -f ${tmppublicpath}/statusdaq.finished
    110     ${scriptpath}/statusdaq.sh > ${OUT1}
    111     while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
    112         sleep 30
    113     done
    114     $RM ${tmppublicpath}/statusdaq.finished
     110    $ECHO "FATAL (${scriptName}): ${OUT1} has a problem"
     111    exit 1
     112#    $RM -f ${tmppublicpath}/statusdaq.finished
     113#    ${scriptpath}/statusdaq.sh > ${OUT1}
     114#    while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
     115#       sleep 30
     116#    done
     117#    $RM ${tmppublicpath}/statusdaq.finished
    115118#protect against remove/rewriting   
    116     $CHMOD -v 444 ${OUT1}
     119#    $CHMOD -v 444 ${OUT1}
     120#
    117121fi
    118122
     
    136140  $ECHO "DEBUG (${scriptName}): irods root dir $i"
    137141  dateDAQ=`$ECHO ${i} | $AWK '{split($0,a,"/"); print a[6];}' | $AWK "{sub(/${srclower}/,\"\"); print}"`
     142#JEC 1/10/11 Use generic baodaqstatus name
    138143#Look if the date has changed since beginning of the job!
    139   curtag=`${DATE} +%F`
    140   if [ "<${curtag}>" != "<${tag}>" ]; then
    141       tag=${curtag}
     144#  curtag=`${DATE} +%F`
     145#  if [ "<${curtag}>" != "<${tag}>" ]; then
     146#      tag=${curtag}
    142147#it is necessary to update the daq status as the day has changed during the processing... (batch can take a long time...)
    143       OUT1=${publicpath}/baodaqstatus-${curtag}.txt
    144       $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    145       $RM -f ${tmppublicpath}/statusdaq.finished
    146       ${scriptpath}/statusdaq.sh > ${OUT1}
    147       while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
    148           sleep 30
    149       done
    150       $RM ${tmppublicpath}/statusdaq.finished
     148#      OUT1=${publicpath}/baodaqstatus-${curtag}.txt
     149#      $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
     150#      $RM -f ${tmppublicpath}/statusdaq.finished
     151#      ${scriptpath}/statusdaq.sh > ${OUT1}
     152#      while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
     153#         sleep 30
     154#      done
     155#      $RM ${tmppublicpath}/statusdaq.finished
    151156#protect against remove/rewriting   
    152       $CHMOD -v 444 ${OUT1}
    153   fi
     157#      $CHMOD -v 444 ${OUT1}
     158#  fi
    154159#
    155160# look if the fits file of the gains already exists
Note: See TracChangeset for help on using the changeset viewer.