Changeset 540


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)

Location:
BAORadio/AmasNancay
Files:
1 added
21 edited

Legend:

Unmodified
Added
Removed
  • BAORadio/AmasNancay/analyse.cc

    r527 r540  
    8787   if( left.size() < right.size() )
    8888      return true;
    89    return false;
     89   ////////////POSSIBLY A BUG return false;
    9090   for( string::const_iterator lit = left.begin(), rit = right.begin(); lit != left.end() && rit != right.end(); ++lit, ++rit )
    9191      if( tolower( *lit ) < tolower( *rit ) )
     
    9393      else if( tolower( *lit ) > tolower( *rit ) )
    9494         return false;
     95   return false; ///////TO BE FIXED
    9596}//JEC 22/9/11 comparison, not case sensitive to sort File liste END
    9697//-----
  • BAORadio/AmasNancay/anarawonoffmaker.sh

    r535 r540  
    3737  case "$1" in
    3838      -src)  sourceRadio=$2;    shift;;
    39 -date) dateSelected=$2;     shift;;
    40 -sim)  simulationMode=On;;
    41 -h)
    42 echo >&2 \
    43     "usage: $0 -src souce -date YYYYMMDD [-freq freq in MHz (default ${freqBAOCalib})] [-sim to trig simulation mode]"
    44 exit 1;;
    45 *)  break;;     # terminate while loop
    46 esac
    47 shift
     39      -date) dateSelected=$2;     shift;;
     40      -sim)  simulationMode=On;;
     41      -h)
     42      echo >&2 \
     43          "usage: $0 -src souce -date YYYYMMDD [-freq freq in MHz (default ${freqBAOCalib})] [-sim to trig simulation mode]"
     44      exit 1;;
     45      *)  break;;       # terminate while loop
     46  esac
     47  shift
    4848done
    4949
     
    100100scriptpath="/afs/in2p3.fr/home/c/campagne/private/work/AmasNancay"
    101101
     102#JEC 1/10/11 Use generic baodaqstatus name
    102103#get the daq current irod status
    103 tag=`${DATE} +%F`
    104 OUT1=${publicpath}/baodaqstatus-${tag}.txt
     104#tag=`${DATE} +%F`
     105#OUT1=${publicpath}/baodaqstatus-${tag}.txt
     106OUT1=${publicpath}/baodaqstatus-current.txt
    105107
    106108if [ ! -e ${OUT1}  -o ! -r ${OUT1} ]; then
    107     $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    108     $RM -f ${tmppublicpath}/statusdaq.finished
    109     ${scriptpath}/statusdaq.sh > ${OUT1}
    110     while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
    111         sleep 30
    112     done
    113     $RM ${tmppublicpath}/statusdaq.finished
     109    $ECHO "FATAL (${scriptName}): ${OUT1} has a problem"
     110    exit 1
     111#    $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
     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
    114118#protect against remove/rewriting   
    115     $CHMOD -v 444 ${OUT1}
     119#    $CHMOD -v 444 ${OUT1}
    116120fi
    117121
     
    140144
    141145
     146#JEC 1/10/11 Use generic baodaqstatus name
    142147#Look if the date has changed since beginning of the job!
    143   curtag=`${DATE} +%F`
    144   if [ "<${curtag}>" != "<${tag}>" ]; then
    145       tag=${curtag}
     148#  curtag=`${DATE} +%F`
     149#  if [ "<${curtag}>" != "<${tag}>" ]; then
     150#      tag=${curtag}
    146151#it is necessary to update the daq status as the day has changed during the processing... (batch can take a long time...)
    147       OUT1=${publicpath}/baodaqstatus-${curtag}.txt
    148       $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    149       $RM -f ${tmppublicpath}/statusdaq.finished
    150       ${scriptpath}/statusdaq.sh > ${OUT1}
    151       while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
    152           sleep 30
    153       done
    154       $RM ${tmppublicpath}/statusdaq.finished
     152#      OUT1=${publicpath}/baodaqstatus-${curtag}.txt
     153#      $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
     154#      $RM -f ${tmppublicpath}/statusdaq.finished
     155#      ${scriptpath}/statusdaq.sh > ${OUT1}
     156#     while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
     157#         sleep 30
     158#      done
     159#      $RM ${tmppublicpath}/statusdaq.finished
    155160#protect against remove/rewriting   
    156       $CHMOD -v 444 ${OUT1}
    157   fi
     161#      $CHMOD -v 444 ${OUT1}
     162#  fi
    158163#
    159164# look if the gain & calibration files exist
  • BAORadio/AmasNancay/calibmaker.sh

    r529 r540  
    102102scriptpath="/afs/in2p3.fr/home/c/campagne/private/work/AmasNancay"
    103103
     104#JEC 1/10/11 Use generic baodaqstatus name
     105OUT1=${publicpath}/baodaqstatus-current.txt
     106#
    104107#get the daq current irod status
    105 tag=`${DATE} +%F`
    106 OUT1=${publicpath}/baodaqstatus-${tag}.txt
    107 
     108#tag=`${DATE} +%F`
     109#OUT1=${publicpath}/baodaqstatus-${tag}.txt
     110#
    108111if [ ! -e ${OUT1}  -o ! -r ${OUT1} ]; then
    109     $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    110     $RM -f ${tmppublicpath}/statusdaq.finished
    111     ${scriptpath}/statusdaq.sh > ${OUT1}
    112     while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
    113         sleep 30
    114     done
    115     $RM ${tmppublicpath}/statusdaq.finished
     112    $ECHO "FATAL (${scriptName}): ${OUT1} has a problem"
     113    exit 1
     114#    $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
     115#    $RM -f ${tmppublicpath}/statusdaq.finished
     116#   ${scriptpath}/statusdaq.sh > ${OUT1}
     117#    while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
     118#       sleep 30
     119#    done
     120#    $RM ${tmppublicpath}/statusdaq.finished
    116121#protect against remove/rewriting   
    117     $CHMOD -v 444 ${OUT1}
     122#    $CHMOD -v 444 ${OUT1}
    118123fi
    119124
     
    143148
    144149
     150#JEC 1/10/11 Use generic baodaqstatus name
    145151#Look if the date has changed since beginning of the job!
    146   curtag=`${DATE} +%F`
    147   if [ "<${curtag}>" != "<${tag}>" ]; then
    148       tag=${curtag}
     152#  curtag=`${DATE} +%F`
     153#  if [ "<${curtag}>" != "<${tag}>" ]; then
     154#      tag=${curtag}
    149155#it is necessary to update the daq status as the day has changed during the processing... (batch can take a long time...)
    150       OUT1=${publicpath}/baodaqstatus-${curtag}.txt
    151       $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    152       $RM -f ${tmppublicpath}/statusdaq.finished
    153       ${scriptpath}/statusdaq.sh > ${OUT1}
    154       while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
    155           sleep 30
    156       done
    157       $RM ${tmppublicpath}/statusdaq.finished
     156#      OUT1=${publicpath}/baodaqstatus-${curtag}.txt
     157#      $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
     158#      $RM -f ${tmppublicpath}/statusdaq.finished
     159#      ${scriptpath}/statusdaq.sh > ${OUT1}
     160#      while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
     161#         sleep 30
     162#      done
     163#      $RM ${tmppublicpath}/statusdaq.finished
    158164#protect against remove/rewriting   
    159       $CHMOD -v 444 ${OUT1}
    160   fi
     165#      $CHMOD -v 444 ${OUT1}
     166#  fi
    161167#
    162168# look if the calibration files already exist
  • BAORadio/AmasNancay/etude_gain.pic

    r525 r540  
    22set source "Abell85"
    33set srclower "abell85"
    4 set date   "20110428"
     4set date   "20110507"
    55
    66####################################################
     
    1212openfits ${toppath}/${source}/${date}${srclower}/gain_${date}_${srclower}.fits
    1313del g0 g1
    14 objaoper gain_20110428_abell85 row 0 g0
    15 objaoper gain_20110428_abell85 row 1 g1
     14objaoper gain_${date}_${srclower} row 0 g0
     15objaoper gain_${date}_${srclower} row 1 g1
    1616plot2d g1 (n/8192)*250+1250 val n>0 "red cpts nsta notit"
    1717plot2d g0 (n/8192)*250+1250 val n>0 "same blue cpts nsta notit"
     
    2626
    2727openppf ${toppath}/${source}/${date}${srclower}/gain_monitor_${date}_${srclower}.ppf
     28#attention les "monitor" ont ete utilise a une epoque ou il n'y avait pas de
     29#reordering...
     30plot2d monitor n val n>0 "black cpts nsta notit"
    2831plot2d gainmoni n val n>0 "black cpts nsta notit"
    2932plot2d gainmoni0 n val n>0 "same blue cpts nsta notit"
  • 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
  • BAORadio/AmasNancay/getscafiles.sh

    r516 r540  
    2222  $ECHO "usage: ${script
    2323Name} <source:ex. Abell85> <date:YYYYMMDD>"
    24   touch ${tmppublicpath}/getscafiles.finished
     24#JEC 29/9/11 avoid finished stuff
     25#  touch ${tmppublicpath}/getscafiles.finished
    2526  exit 0
    2627fi
     
    5253else
    5354   $ECHO "FATAL (${scriptName}): environment is ${ENVIRONMENT} not allowed"
    54    touch ${tmppublicpath}/getscafiles.finished
     55#JEC 29/9/11 avoid finished stuff
     56#   touch ${tmppublicpath}/getscafiles.finished
    5557   exit 1
    5658fi
     
    6567scriptpath="/afs/in2p3.fr/home/c/campagne/private/work/AmasNancay"
    6668
     69#JEC 1/10/11 Use generic baodaqstatus name
    6770#look if the run exists
    68 tag=`${DATE} +%F`
    69 OUT1=${publicpath}/baodaqstatus-${tag}.txt
     71#tag=`${DATE} +%F`
     72#OUT1=${publicpath}/baodaqstatus-${tag}.txt
     73OUT1=${publicpath}/baodaqstatus-current.txt
     74
    7075if [ ! -e ${OUT1} -o ! -r ${OUT1} ]; then
    7176#    $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
     
    7984#     $RM ${tmppublicpath}/statusdaq.finished
    8085    $ECHO "FATAL (${scriptName}): ${OUT1} is missing or not readable..."
    81     touch ${tmppublicpath}/getscafiles.finished
     86#JEC 29/9/11 avoid finished stuff
     87#    touch ${tmppublicpath}/getscafiles.finished
    8288    exit 1
    8389fi
     
    8793if [ "<${nfiles}>" = "<>" ]; then
    8894    $ECHO "FATAL (${scriptName}): No run found for <${sourceRadio}> and date <${dateDAQ}>"
    89     touch ${tmppublicpath}/getscafiles.finished
     95#JEC 29/9/11 avoid finished stuff
     96#    touch ${tmppublicpath}/getscafiles.finished
    9097    exit 1
    9198fi
     
    94101#Look if the run should/can be prepared wrt SCA file transformation
    95102OUT2=./scaStatus.$$
    96 $RM -f ${tmppublicpath}/scaextractor.finished
     103#JEC 29/9/11 avoid finished stuff
     104#$RM -f ${tmppublicpath}/scaextractor.finished
    97105${scriptpath}/scaextractor.sh $sourceRadio > ${OUT2} 2>&1
    98 while [ ! -f "${tmppublicpath}/scaextractor.finished" ]; do
    99     $ECHO "INFO (${scriptName}); waiting for ${tmppublicpath}/scaextractor.finished"
    100     date +%T
    101     sleep 30
    102 done
    103 $RM ${tmppublicpath}/scaextractor.finished
     106#while [ ! -f "${tmppublicpath}/scaextractor.finished" ]; do
     107#    $ECHO "INFO (${scriptName}); waiting for ${tmppublicpath}/scaextractor.finished"
     108#    date +%T
     109#    sleep 30
     110#done
     111#$RM ${tmppublicpath}/scaextractor.finished
    104112
    105113
     
    108116if [ "<$status>" != "<>" ]; then
    109117    $ECHO "FATAL (${scriptName}): connot proceed further with $sourceRadio $dateDAQ"
    110     touch ${tmppublicpath}/getscafiles.finished
     118#JEC 29/9/11 avoid finished stuff
     119#    touch ${tmppublicpath}/getscafiles.finished
    111120    exit 1
    112121fi
     
    144153  $ECHO "FATAL (${scriptName}): error while iget:"
    145154  $ECHO $igetStatus
    146   touch ${tmppublicpath}/getscafiles.finished
     155#JEC 29/9/11 avoid finished stuff
     156#  touch ${tmppublicpath}/getscafiles.finished
    147157  exit 1
    148158fi
  • BAORadio/AmasNancay/getsignalfiles.sh

    r516 r540  
    2424if [ ! $# = 4 ]; then
    2525  $ECHO "usage: ${scriptName} <source:ex. Abell85> <date:YYYYMMDD> first last"
    26   touch ${tmppublicpath}/getsignalfiles.finished
     26#JEC 29/9/11 avoid finished stuff
     27#  touch ${tmppublicpath}/getsignalfiles.finished
    2728  exit 0
    2829fi
     
    5253else
    5354   $ECHO "FATAL (${scriptName}): environment is ${ENVIRONMENT} not allowed"
    54    touch ${tmppublicpath}/getsignalfiles.finished
     55#JEC 29/9/11 avoid finished stuff
     56#   touch ${tmppublicpath}/getsignalfiles.finished
    5557   exit 1
    5658fi
     
    6668
    6769#determine the sequence of signal files to download
     70#JEC 1/10/11 Use generic baodaqstatus name
    6871#get the daq current irod status
    69 tag=`${DATE} +%F`
    70 OUT1=${publicpath}/baodaqstatus-${tag}.txt
     72#tag=`${DATE} +%F`
     73#OUT1=${publicpath}/baodaqstatus-${tag}.txt
     74OUT1=${publicpath}/baodaqstatus-current.txt
    7175
    7276if [ ! -e ${OUT1} -o ! -r ${OUT1} ]; then
     
    8286#     $RM ${tmppublicpath}/statusdaq.finished
    8387    $ECHO "FATAL (${scriptName}): ${OUT1} is missing or not readable..."
    84     touch ${tmppublicpath}/getsignalfiles.finished
     88#JEC 29/9/11 avoid finished stuff
     89#    touch ${tmppublicpath}/getsignalfiles.finished
    8590    exit 1
    8691fi
     
    9095    $ECHO "FATAL (${scriptName}): No run found for <${sourceRadio}> and date <${dateDAQ}>"
    9196    $CAT $OUT1
    92     touch ${tmppublicpath}/getsignalfiles.finished
     97#JEC 29/9/11 avoid finished stuff
     98#    touch ${tmppublicpath}/getsignalfiles.finished
    9399    exit 1
    94100fi
     
    98104if [ ${firstFile} -gt  ${nfiles} ]; then
    99105    $ECHO "FATAL (${scriptName}): ${firstFile} >  ${nfiles}"
    100     touch ${tmppublicpath}/getsignalfiles.finished
     106#JEC 29/9/11 avoid finished stuff
     107#    touch ${tmppublicpath}/getsignalfiles.finished
    101108    exit 1
    102109fi
     
    106113if [ ${lastFile} -gt  ${nfiles} ]; then
    107114    $ECHO "FATAL (${scriptName}): ${lastFile} >  ${nfiles}"
    108     touch ${tmppublicpath}/getsignalfiles.finished
     115#JEC 29/9/11 avoid finished stuff
     116#    touch ${tmppublicpath}/getsignalfiles.finished
    109117    exit 1
    110118fi
     
    112120if [ ${firstFile} -gt  ${lastFile} ]; then
    113121    $ECHO "FATAL (${scriptName}): ${firstFile} >  ${lastFile}"
    114     touch ${tmppublicpath}/getsignalfiles.finished
     122#JEC 29/9/11 avoid finished stuff
     123#    touch ${tmppublicpath}/getsignalfiles.finished
    115124    exit 1
    116125fi
     
    134143       $ECHO "FATAL (${scriptName}): error while iget:"
    135144       $ECHO $igetStatus
    136        touch ${tmppublicpath}/getsignalfiles.finished
     145#JEC 29/9/11 avoid finished stuff
     146#       touch ${tmppublicpath}/getsignalfiles.finished
    137147       exit 1
    138148   fi
     
    142152       $ECHO "FATAL (${scriptName}): error while iget:"
    143153       $ECHO $igetStatus
    144        touch ${tmppublicpath}/getsignalfiles.finished
     154#JEC 29/9/11 avoid finished stuff
     155#       touch ${tmppublicpath}/getsignalfiles.finished
    145156       exit 1
    146157   fi
     
    148159done
    149160
    150 touch ${tmppublicpath}/getsignalfiles.finished
     161#JEC 29/9/11 avoid finished stuff
     162#touch ${tmppublicpath}/getsignalfiles.finished
    151163exit 0
  • BAORadio/AmasNancay/hdrfitsextractor.sh

    r510 r540  
    4848
    4949
     50#JEC 1/10/11 Use generic baodaqstatus name
    5051#get the daq current irod status
    51 tag=`${DATE} +%F`
    52 OUT1=${publicpath}/baodaqstatus-${tag}.txt
     52#tag=`${DATE} +%F`
     53#OUT1=${publicpath}/baodaqstatus-${tag}.txt
     54OUT1=${publicpath}/baodaqstatus-current.txt
    5355
    54 if [ ! -e ${OUT1} ]; then
    55     $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    56     ${scriptpath}/statusdaq.sh > ${OUT1}
     56if [ ! -e ${OUT1}  -o ! -r ${OUT1} ]; then
     57    $ECHO "FATAL (${scriptName}): ${OUT1} has a problem"
     58    exit 1
    5759fi
     60
     61#if [ ! -e ${OUT1} ]; then
     62#    $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
     63#    ${scriptpath}/statusdaq.sh > ${OUT1}
     64#fi
    5865
    5966if [ ! "<${sourceRadio}>" = "<>" ]; then
  • BAORadio/AmasNancay/makefile

    r507 r540  
    77PKGOLIST =
    88
    9 EXELIST = $(EXE)analyse
     9EXELIST = $(EXE)analyse $(EXE)mergeRawOnOff
    1010
    11 EXEOLIST = $(EXE)analyse.o
     11EXEOLIST = $(EXE)analyse.o $(EXE)mergeRawOnOff.o
    1212
    1313
    14 all : analyse
     14all : analyse mergeRawOnOff
    1515
    1616clean :
     
    2929        $(CXXCOMPILE) -c  -o $(OBJ)analyse.o analyse.cc
    3030
     31mergeRawOnOff : $(EXE)mergeRawOnOff
     32        echo '---mergeRawOnOff made'
     33
     34$(EXE)mergeRawOnOff : $(OBJ)mergeRawOnOff.o
     35        $(CXXLINK) -o $(EXE)mergeRawOnOff $(OBJ)mergeRawOnOff.o  $(SOPHYAALLSLBLIST)
     36
     37$(OBJ)mergeRawOnOff.o : mergeRawOnOff.cc
     38        $(CXXCOMPILE) -c  -o $(OBJ)mergeRawOnOff.o mergeRawOnOff.cc
     39 
  • BAORadio/AmasNancay/onoffmaker.sh

    r529 r540  
    102102scriptpath="/afs/in2p3.fr/home/c/campagne/private/work/AmasNancay"
    103103
     104#JEC 1/10/11 Use generic baodaqstatus name
    104105#get the daq current irod status
    105 tag=`${DATE} +%F`
    106 OUT1=${publicpath}/baodaqstatus-${tag}.txt
     106#tag=`${DATE} +%F`
     107#OUT1=${publicpath}/baodaqstatus-${tag}.txt
     108OUT1=${publicpath}/baodaqstatus-current.txt
    107109
    108110if [ ! -e ${OUT1}  -o ! -r ${OUT1} ]; then
    109     $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    110     $RM -f ${tmppublicpath}/statusdaq.finished
    111     ${scriptpath}/statusdaq.sh > ${OUT1}
    112     while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
    113         sleep 30
    114     done
    115     $RM ${tmppublicpath}/statusdaq.finished
     111    $ECHO "FATAL (${scriptName}): ${OUT1} has a problem"
     112    exit 1
     113#    $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
     114#    $RM -f ${tmppublicpath}/statusdaq.finished
     115#    ${scriptpath}/statusdaq.sh > ${OUT1}
     116#    while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
     117#       sleep 30
     118#    done
     119#    $RM ${tmppublicpath}/statusdaq.finished
    116120#protect against remove/rewriting   
    117     $CHMOD -v 444 ${OUT1}
     121#    $CHMOD -v 444 ${OUT1}
    118122fi
    119123
     
    143147
    144148
     149#JEC 1/10/11 Use generic baodaqstatus name
    145150#Look if the date has changed since beginning of the job!
    146   curtag=`${DATE} +%F`
    147   if [ "<${curtag}>" != "<${tag}>" ]; then
    148       tag=${curtag}
     151#  curtag=`${DATE} +%F`
     152#  if [ "<${curtag}>" != "<${tag}>" ]; then
     153#      tag=${curtag}
    149154#it is necessary to update the daq status as the day has changed during the processing... (batch can take a long time...)
    150       OUT1=${publicpath}/baodaqstatus-${curtag}.txt
    151       $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    152       $RM -f ${tmppublicpath}/statusdaq.finished
    153       ${scriptpath}/statusdaq.sh > ${OUT1}
    154       while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
    155           sleep 30
    156       done
    157       $RM ${tmppublicpath}/statusdaq.finished
     155#      OUT1=${publicpath}/baodaqstatus-${curtag}.txt
     156#      $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
     157#      $RM -f ${tmppublicpath}/statusdaq.finished
     158#      ${scriptpath}/statusdaq.sh > ${OUT1}
     159#      while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
     160#         sleep 30
     161#      done
     162#      $RM ${tmppublicpath}/statusdaq.finished
    158163#protect against remove/rewriting   
    159       $CHMOD -v 444 ${OUT1}
    160   fi
     164#      $CHMOD -v 444 ${OUT1}
     165#  fi
    161166#
    162167# look if the gain & calibration files exist
  • BAORadio/AmasNancay/proc_rawonoff.sh

    r535 r540  
    126126$ECHO "DEBUG (${scriptName}): START call getscafiles.sh ${sourceRadio} ${dateSelected}"
    127127OUT1=./getScaStatus.$$
    128 $RM -f ${tmppublicpath}/getscafiles.finished
     128#JEC 29/9/11 avoid finished stuff
     129#$RM -f ${tmppublicpath}/getscafiles.finished
    129130${scriptpath}/getscafiles.sh ${sourceRadio} ${dateSelected} > ${OUT1} 2>&1
    130 while [ ! -f "${tmppublicpath}/getscafiles.finished" ]; do
    131     $ECHO "INFO (${scriptName}): waiting for ${tmppublicpath}/getscafiles.finished"
    132     date +%T
    133     sleep 30
    134 done
    135 $RM -f ${tmppublicpath}/getscafiles.finished
     131#while [ ! -f "${tmppublicpath}/getscafiles.finished" ]; do
     132#    $ECHO "INFO (${scriptName}): waiting for ${tmppublicpath}/getscafiles.finished"
     133#    date +%T
     134#    sleep 30
     135#done
     136#$RM -f ${tmppublicpath}/getscafiles.finished
    136137$ECHO "DEBUG (${scriptName}): END"
    137138
     
    144145  $CAT ${OUT1}
    145146  $ECHO "DEBUG (${scriptName}): END"
    146   touch ${tmppublicpath}/proc_script.finished
     147#JEC 29/9/11 avoid finished stuff
     148#  touch ${tmppublicpath}/proc_script.finished
    147149  exit 1
    148150fi
     
    155157  $CAT ${OUT1}
    156158  $ECHO "DEBUG (${scriptName}): END"
    157   touch ${tmppublicpath}/proc_script.finished
     159#JEC 29/9/11 avoid finished stuff
     160#  touch ${tmppublicpath}/proc_script.finished
    158161  exit 1
    159162fi
     
    189192          $ECHO "FATAL (${scriptName}): error while iget:"
    190193          $ECHO $igetStatus
    191           touch ${tmppublicpath}/proc_script.finished
     194#JEC 29/9/11 avoid finished stuff
     195#         touch ${tmppublicpath}/proc_script.finished
    192196          exit 1
    193197      fi
     
    200204#Get list of file to process
    201205headerFileSelected=./selectSignal.$$
    202 $RM -f ${tmppublicpath}/select.finished
     206#JEC 29/9/11 avoid finished stuff
     207#$RM -f ${tmppublicpath}/select.finished
    203208${scriptpath}/select.sh ${scaFileSummarized} ${dirFiberfile} ${typeofproc} | $GREP "^#[0-9]" | $SED "s/^#//" > $headerFileSelected
    204 while [ ! -f "${tmppublicpath}/select.finished" ]; do
    205     $ECHO "INFO (${scriptName}): waiting for ${tmppublicpath}/select.finished"
    206     date +%T
    207     sleep 30
    208 done
    209 $RM ${tmppublicpath}/select.finished
     209#while [ ! -f "${tmppublicpath}/select.finished" ]; do
     210#    $ECHO "INFO (${scriptName}): waiting for ${tmppublicpath}/select.finished"
     211#    date +%T
     212#    sleep 30
     213#done
     214#$RM ${tmppublicpath}/select.finished
    210215#
    211216$ECHO "DEBUG (${scriptName}): END"
     
    229234if [ ${#cycleArray[*]} -eq 0 -o ${#filesArray[*]} -eq 0 ]; then
    230235   $ECHO "FATAL (${scriptName}): no header file selected (${#cycleArray[*]}, ${#filesArray[*]})"
    231    touch ${tmppublicpath}/proc_script.finished
     236#JEC 29/9/11 avoid finished stuff
     237#   touch ${tmppublicpath}/proc_script.finished
    232238   exit 1
    233239else
     
    326332    $ECHO "FATAL (${scriptName}): type of processing"
    327333    usage
    328     touch ${tmppublicpath}/proc_script.finished
     334#JEC 29/9/11 avoid finished stuff
     335#    touch ${tmppublicpath}/proc_script.finished
    329336    exit 1
    330337    ;;
     
    387394if [ ! -e $prg ]; then
    388395    $ECHO "FATAL (${scriptName}): $prg not found"
    389     touch ${tmppublicpath}/proc_script.finished
     396#JEC 29/9/11 avoid finished stuff
     397#    touch ${tmppublicpath}/proc_script.finished
    390398    exit 1
    391399fi
     
    417425        $ECHO "FATAL (${scriptName}): error while iget:"
    418426        $ECHO $igetStatus
    419         touch ${tmppublicpath}/${jobBatchName}.finished
     427#JEC 29/9/11 avoid finished stuff
     428#       touch ${tmppublicpath}/${jobBatchName}.finished
    420429        exit 1
    421430    fi
     
    426435for ((i=${firstCycleId};i<${lastp1CycleId};i++)); do
    427436#
     437
     438####
     439# Check daq status
     440#JEC 1/10/11 Use generic baodaqstatus name
     441####
     442#get the daq current irod status
     443#tag=`${DATE} +%F`
     444#OUT1=${publicpath}/baodaqstatus-${tag}.txt
     445OUT1=${publicpath}/baodaqstatus-current.txt
     446
     447if [ ! -e ${OUT1}  -o ! -r ${OUT1} ]; then
     448    $ECHO "FATAL (${scriptName}): ${OUT1} has a problem"
     449    exit 1
     450#    $ECHO "We should bring the DAQ status more up to date, this take 1 or 2min..."
     451#JEC 29/9/11 avoid finished stuff
     452#    $RM -f ${tmppublicpath}/statusdaq.finished
     453#    ${scriptpath}/statusdaq.sh > ${OUT1}
     454#    while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
     455#       sleep 30
     456#    done
     457#    $RM ${tmppublicpath}/statusdaq.finished
     458#protect against remove/rewriting   
     459#    $CHMOD -v 444 ${OUT1}
     460fi
     461
    428462#time window selection
    429463    tmproc="-tmproc ${timeArray[${i}]},${timeDuration}"
     
    455489#get signals files
    456490    OUT3=./getsignals.$$
    457     $RM -f ${tmppublicpath}/getsignalfiles.finished
     491#JEC 29/9/11 avoid finished stuff
     492#    $RM -f ${tmppublicpath}/getsignalfiles.finished
    458493    ${scriptpath}/getsignalfiles.sh ${sourceRadio} ${dateSelected} ${firstFile}  ${lastFile} > ${OUT3} 2>&1
    459     while [ ! -f "${tmppublicpath}/getsignalfiles.finished" ]; do
    460         $ECHO "INFO (${scriptName}): waiting for ${tmppublicpath}/getsignalfiles.finished"
    461         date +%T
    462         sleep 30
    463     done
    464     $RM ${tmppublicpath}/getsignalfiles.finished
     494#    while [ ! -f "${tmppublicpath}/getsignalfiles.finished" ]; do
     495#       $ECHO "INFO (${scriptName}): waiting for ${tmppublicpath}/getsignalfiles.finished"
     496#       date +%T
     497#       sleep 30
     498#    done
     499#    $RM ${tmppublicpath}/getsignalfiles.finished
    465500
    466501    getSignals=`$GREP "^FATAL" ${OUT3}`
     
    468503        $ECHO "FATAL (${scriptName}): error while get signals"
    469504        $ECHO $getSignals
    470         touch ${tmppublicpath}/${jobBatchName}.finished
     505#JEC 29/9/11 avoid finished stuff
     506#       touch ${tmppublicpath}/${jobBatchName}.finished
    471507        exit 1
    472508    fi
     
    511547$ECHO "DEBUG (${scriptName}): END loop on cycles"
    512548#
    513 touch ${tmppublicpath}/proc_script.finished
     549#JEC 29/9/11 avoid finished stuff
     550#touch ${tmppublicpath}/proc_script.finished
    514551exit 0
  • BAORadio/AmasNancay/rawonoffmaker.sh

    r530 r540  
    101101
    102102#get the daq current irod status
    103 tag=`${DATE} +%F`
    104 OUT1=${publicpath}/baodaqstatus-${tag}.txt
     103#tag=`${DATE} +%F`
     104#OUT1=${publicpath}/baodaqstatus-${tag}.txt
     105####JEC 1/10/11 tag=`${DATE} +%F`
     106#Use generic baodaqstatus name
     107OUT1=${publicpath}/baodaqstatus-current.txt
    105108
    106109if [ ! -e ${OUT1}  -o ! -r ${OUT1} ]; then
    107     $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    108     $RM -f ${tmppublicpath}/statusdaq.finished
    109     ${scriptpath}/statusdaq.sh > ${OUT1}
    110     while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
    111         sleep 30
    112     done
    113     $RM ${tmppublicpath}/statusdaq.finished
     110    $ECHO "FATAL (${scriptName}): ${OUT1} has a problem"
     111    exit 1
     112#JEC 29/9/11 avoid finished stuff
     113#    $RM -f ${tmppublicpath}/statusdaq.finished
     114#    ${scriptpath}/statusdaq.sh > ${OUT1}
     115#    while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
     116#       sleep 30
     117#    done
     118#    $RM ${tmppublicpath}/statusdaq.finished
    114119#protect against remove/rewriting   
    115     $CHMOD -v 444 ${OUT1}
     120#    $CHMOD -v 444 ${OUT1}
    116121fi
     122
     123
    117124
    118125
     
    140147  $LS -lrt
    141148
    142 
     149#JEC 1/10/11 Use generic baodaqstatus name
    143150#Look if the date has changed since beginning of the job!
    144   curtag=`${DATE} +%F`
    145   if [ "<${curtag}>" != "<${tag}>" ]; then
    146       tag=${curtag}
     151#  curtag=`${DATE} +%F`
     152#  if [ "<${curtag}>" != "<${tag}>" ]; then
     153#      tag=${curtag}
    147154#it is necessary to update the daq status as the day has changed during the processing... (batch can take a long time...)
    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
     155#      OUT1=${publicpath}/baodaqstatus-${curtag}.txt
     156#     $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
     157#      $RM -f ${tmppublicpath}/statusdaq.finished
     158#      ${scriptpath}/statusdaq.sh > ${OUT1}
     159#      while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
     160#         sleep 30
     161#      done
     162#      $RM ${tmppublicpath}/statusdaq.finished
    156163#protect against remove/rewriting   
    157       $CHMOD -v 444 ${OUT1}
    158   fi
     164#      $CHMOD -v 444 ${OUT1}
     165#  fi
    159166#
    160167# look if the gain & calibration files exist
  • BAORadio/AmasNancay/sca.sh

    r516 r540  
    4343else
    4444    $ECHO "FATAL (${scriptName}): environment is ${ENVIRONMENT} not allowed"
    45     touch ${tmppublicpath}/sca.finished
     45#JEC 29/9/11 avoid finished stuff
     46#    touch ${tmppublicpath}/sca.finished
    4647    exit 1
    4748fi
     
    5253    then
    5354    $ECHO "FATAL  (${scriptName}): usage: ./sca.sh <file>"
    54     touch ${tmppublicpath}/sca.finished
     55#JEC 29/9/11 avoid finished stuff
     56#    touch ${tmppublicpath}/sca.finished
    5557    exit 1
    5658fi
     
    6163    then
    6264    $ECHO "FATAL (${scriptName}): $fullfile not found: FATAL"
    63     touch ${tmppublicpath}/sca.finished
     65#JEC 29/9/11 avoid finished stuff
     66#    touch ${tmppublicpath}/sca.finished
    6467    exit 1
    6568fi
     
    171174$RM $OUT2
    172175
    173 touch ${tmppublicpath}/sca.finished
     176#JEC 29/9/11 avoid finished stuff
     177#touch ${tmppublicpath}/sca.finished
    174178exit 0
    175179
  • BAORadio/AmasNancay/scaIsOk.sh

    r513 r540  
    5555
    5656
     57#JEC 1/10/11 Use generic baodaqstatus name
    5758#get the daq current irod status
    58 tag=`${DATE} +%F`
    59 OUT1=${publicpath}/baodaqstatus-${tag}.txt
    60 OUT1=${publicpath}/baodaqstatus-2011-09-11.txt
     59#tag=`${DATE} +%F`
     60#OUT1=${publicpath}/baodaqstatus-${tag}.txt
     61#OUT1=${publicpath}/baodaqstatus-2011-09-11.txt
     62OUT1=${publicpath}/baodaqstatus-current.txt
     63
    6164
    6265if [ ! -e ${OUT1} -o ! -r ${OUT1} ]; then
    6366    $ECHO "FATAL (${scriptName}): ${OUT1} is missing or not readable..."
    64     touch ${tmppublicpath}/scaIsOk.finished
     67#    touch ${tmppublicpath}/scaIsOk.finished
    6568    exit 1
    6669fi
  • BAORadio/AmasNancay/scaextractor.sh

    r516 r540  
    4040else
    4141    $ECHO "FATAL (${scriptName}): environment is ${ENVIRONMENT} not allowed"
    42     touch ${tmppublicpath}/scaextractor.finished
     42#JEC 29/9/11 avoid finished stuff
     43#    touch ${tmppublicpath}/scaextractor.finished
    4344    exit 1
    4445fi
     
    5556
    5657
     58#JEC 1/10/11 Use generic baodaqstatus name
    5759#get the daq current irod status
    58 tag=`${DATE} +%F`
    59 OUT1=${publicpath}/baodaqstatus-${tag}.txt
     60#tag=`${DATE} +%F`
     61#OUT1=${publicpath}/baodaqstatus-${tag}.txt
     62OUT1=${publicpath}/baodaqstatus-current.txt
     63
    6064
    6165if [ ! -e ${OUT1} -o ! -r ${OUT1} ]; then
     66    $ECHO "FATAL (${scriptName}): ${OUT1} has a problem"
     67    exit 1
    6268#    $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    6369#    $RM -f ${tmppublicpath}/statusdaq.finished
     
    6975#    done
    7076#    $RM ${tmppublicpath}/statusdaq.finished
    71     $ECHO "FATAL (${scriptName}): ${OUT1} is missing or not readable..."
    72     touch ${tmppublicpath}/scaextractor.finished
    73     exit 1
     77#    $ECHO "FATAL (${scriptName}): ${OUT1} is missing or not readable..."
     78#JEC 29/9/11 avoid finished stuff
     79#    touch ${tmppublicpath}/scaextractor.finished
     80#    exit 1
    7481fi
    7582
     
    106113        iget -r -f -v -K ${i}/${scafile} ${iojobpath}
    107114#extract summary (sum extension)
     115#JEC 29/9/11 avoid finished stuff
    108116        $RM -f ${tmppublicpath}/sca.finished
    109117        ${scriptpath}/sca.sh ${scafile}
    110         while [ ! -e "${tmppublicpath}/sca.finished" ]; do
    111             $ECHO "INFO (${scriptName}); waiting for ${tmppublicpath}/sca.finished"
    112             date +%T
    113             sleep 30
    114         done
     118#       while [ ! -e "${tmppublicpath}/sca.finished" ]; do
     119#           $ECHO "INFO (${scriptName}); waiting for ${tmppublicpath}/sca.finished"
     120#           date +%T
     121#           sleep 30
     122#       done
    115123        $ECHO "INFO (${scriptName}): sca.sh has finished"
    116         $RM ${tmppublicpath}/sca.finished
     124#       $RM ${tmppublicpath}/sca.finished
    117125#TODO see if there is errors...
    118126        scaFileName=$(basename $scafile)
    119127        scaFileName=${scaFileName%.*}
    120128#transform the date (sum.trans extension)
    121         $RM -f ${tmppublicpath}/transdate.finished
     129#JEC 29/9/11 avoid finished stuff
     130#       $RM -f ${tmppublicpath}/transdate.finished
    122131        ${scriptpath}/transdate.sh ${scaFileName}.sum
    123         while [ ! -e "${tmppublicpath}/transdate.finished" ]; do
    124             $ECHO "INFO (${scriptName}); waiting for ${tmppublicpath}/transdate.finished"
    125             date +%T
    126             sleep 30
    127         done
     132#       while [ ! -e "${tmppublicpath}/transdate.finished" ]; do
     133#           $ECHO "INFO (${scriptName}); waiting for ${tmppublicpath}/transdate.finished"
     134#           date +%T
     135#           sleep 30
     136#       done
    128137        $ECHO "INFO (${scriptName}): transdate.sh  has finished"
    129         $RM ${tmppublicpath}/transdate.finished
     138#       $RM ${tmppublicpath}/transdate.finished
    130139#TODO see if there is errors...
    131140#put back into Irod
     
    142151
    143152
    144 touch ${tmppublicpath}/scaextractor.finished
     153#JEC 29/9/11 avoid finished stuff
     154#touch ${tmppublicpath}/scaextractor.finished
    145155exit 0
  • BAORadio/AmasNancay/select.sh

    r516 r540  
    2626if [ ! $# = 3 ]; then
    2727  $ECHO "usage: ${scriptName} <scaXYZ.sum> <signalXYZDirectory> <type of phase:ON|OFF|CALIBON|CALIBOFF>"
    28   touch ${tmppublicpath}/select.finished
     28#JEC 29/9/11 avoid finished stuff
     29#  touch ${tmppublicpath}/select.finished
    2930  exit 0
    3031fi
     
    4849if [ ! -e $inScaFile ]; then
    4950  $ECHO "FATAL (${scriptName}): $inScaFile not found"
    50   touch ${tmppublicpath}/select.finished
     51#JEC 29/9/11 avoid finished stuff
     52#  touch ${tmppublicpath}/select.finished
    5153  exit 1
    5254fi
     
    6971    *)
    7072    $ECHO "FATAL (${scriptName}): use ON|OFF|CALIBON|CALIBOFF phase tags."
    71     touch ${tmppublicpath}/select.finished
     73#JEC 29/9/11 avoid finished stuff
     74#    touch ${tmppublicpath}/select.finished
    7275    exit 1
    7376    ;;
     
    224227$RM $OUT2
    225228
    226 touch ${tmppublicpath}/select.finished
     229#JEC 29/9/11 avoid finished stuff
     230#touch ${tmppublicpath}/select.finished
    227231exit 0
  • BAORadio/AmasNancay/statusdaq.sh

    r516 r540  
    3838else
    3939    $ECHO "FATAL (${scriptName}): environment is ${ENVIRONMENT} not allowed"
    40     touch ${tmppublicpath}/statusdaq.finished
     40#JEC 29/9/11 avoid finished stuff
     41#    touch ${tmppublicpath}/statusdaq.finished
    4142    exit 1
    4243fi
     
    8586done
    8687
    87 touch ${tmppublicpath}/statusdaq.finished
     88#JEC 29/9/11 avoid finished stuff
     89#touch ${tmppublicpath}/statusdaq.finished
    8890exit 0
  • BAORadio/AmasNancay/submit2bqs-anarawonoffmaker.sh

    r530 r540  
    1818      simulationMode="-sim On"
    1919      $ECHO "INFO ${scriptName} running in SIMUL mode";;
    20         -h)
     20      -h)
    2121        echo >&2 \
    2222            "usage: $0 -src souce -date YYYYMMDD [-freq freq in MHz (default ${freqBAOCalib})] [-sim to trig simulation mode]"
  • BAORadio/AmasNancay/submit2bqs-rawonoffmaker.sh

    r535 r540  
    7777scriptpath="/afs/in2p3.fr/home/c/campagne/private/work/AmasNancay"
    7878#get the daq current irod status
    79 tag=`${DATE} +%F`
    80 OUT1=${publicpath}/baodaqstatus-${tag}.txt
     79#JEC 1/10/11 Use generic baodaqstatus name
     80#### tag=`${DATE} +%F`
     81OUT1=${publicpath}/baodaqstatus-current.txt
    8182
    8283if [ ! -e ${OUT1}  -o ! -r ${OUT1} ]; then
    83     $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    84     $RM -f ${tmppublicpath}/statusdaq.finished
    85     ${scriptpath}/statusdaq.sh > ${OUT1}
    86     while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
    87         sleep 30
    88     done
    89     $RM ${tmppublicpath}/statusdaq.finished
     84    $ECHO "FATAL (${scriptName}): ${OUT1} has a problem"
     85    exit 1
     86#JEC 29/9/11 avoid finished stuff
     87#    $RM -f ${tmppublicpath}/statusdaq.finished
     88#    ${scriptpath}/statusdaq.sh > ${OUT1}
     89#    while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
     90#       sleep 30
     91#    done
     92#    $RM ${tmppublicpath}/statusdaq.finished
    9093#protect against remove/rewriting   
    91     $CHMOD -v 444 ${OUT1}
     94#    $CHMOD -v 444 ${OUT1}
    9295fi
    9396
  • BAORadio/AmasNancay/submit2bqs-scaextractor.sh

    r516 r540  
    4343scriptpath="/afs/in2p3.fr/home/c/campagne/private/work/AmasNancay"
    4444
     45#JEC 1/10/11 Use generic baodaqstatus name
    4546#the daq current irod status
    46 tag=`${DATE} +%F`
    47 OUT1=${publicpath}/baodaqstatus-${tag}.txt
     47#tag=`${DATE} +%F`
     48#OUT1=${publicpath}/baodaqstatus-${tag}.txt
     49OUT1=${publicpath}/baodaqstatus-current.txt
    4850
    4951if [ ! -e ${OUT1}  -o ! -r ${OUT1} ]; then
    50     $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
    51     $RM -f ${tmppublicpath}/statusdaq.finished
    52     ${scriptpath}/statusdaq.sh > ${OUT1}
    53     while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
    54         sleep 30
    55     done
    56     $RM ${tmppublicpath}/statusdaq.finished
     52    $ECHO "FATAL (${scriptName}): ${OUT1} has a problem"
     53    exit 1
     54#    $ECHO "We should bring the DAQ status more up to date, this take 1 or 2sec..."
     55#    $RM -f ${tmppublicpath}/statusdaq.finished
     56#    ${scriptpath}/statusdaq.sh > ${OUT1}
     57#    while [ ! -f "${tmppublicpath}/statusdaq.finished" ]; do
     58#       sleep 30
     59#    done
     60#    $RM ${tmppublicpath}/statusdaq.finished
    5761#protect against remove/rewriting   
    58     $CHMOD -v 444 ${OUT1}
     62#    $CHMOD -v 444 ${OUT1}
    5963fi
    6064
  • BAORadio/AmasNancay/transdate.sh

    r516 r540  
    3333else
    3434     $ECHO "FATAL (${scriptName}): environment is ${ENVIRONMENT} not allowed"
    35     touch ${tmppublicpath}/transdate.finished
     35#JEC 29/9/11 avoid finished stuff
     36#    touch ${tmppublicpath}/transdate.finished
    3637    exit 1
    3738fi
     
    4041if [ ! $# = 1 ]; then
    4142  $ECHO "FATAL (${scriptName}) usage: ./transdate.sh <scaXYZ.sum>"
    42   touch ${tmppublicpath}/transdate.finished
     43#JEC 29/9/11 avoid finished stuff
     44#  touch ${tmppublicpath}/transdate.finished
    4345  exit 0
    4446fi
     
    4850if [ ! -e $inScaFile ]; then
    4951  $ECHO "FATAL (${scriptName}): $inScaFile not found"
    50   touch ${tmppublicpath}/transdate.finished
     52#JEC 29/9/11 avoid finished stuff
     53#  touch ${tmppublicpath}/transdate.finished
    5154  exit 1
    5255fi
     
    7679' $inScaFile >> $inScaFile.trans
    7780
    78 touch ${tmppublicpath}/transdate.finished
     81#JEC 29/9/11 avoid finished stuff
     82#touch ${tmppublicpath}/transdate.finished
    7983exit 0
Note: See TracChangeset for help on using the changeset viewer.