Ignore:
Timestamp:
02/19/09 21:22:19 (16 years ago)
Author:
Daniela Dorner
Message:
*** empty log message ***
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/datacenter/scripts/writesequencefiles

    r9054 r9355  
    4242set -C
    4343
    44 scriptlog=$runlogpath/$program-$datetime.log
    45 date >> $scriptlog 2>&1
    46 
    4744# check if script is already running
    4845lockfile=$lockpath/lock-$program.txt
    49 checklock  >> $scriptlog 2>&1
     46checklock
    5047
    5148# get todo list
    52 gettodo  >> $scriptlog 2>&1
     49gettodo
    5350
    5451cd $mars
     
    6360   no2=`printf %08d $sequence`
    6461   sequencepath=$sequpath/$no
    65    makedir $sequencepath >> $scriptlog 2>&1
     62   makedir $sequencepath
    6663
    6764   writesequencefilelogpath=$logpath/$program/$no
    68    makedir $writesequencefilelogpath >> $scriptlog 2>&1
     65   makedir $writesequencefilelogpath
    6966   writesequencefilelog=$writesequencefilelogpath/writesequencefile-$no2.log
    7067
    71    echo "write sequencefile for sequence $sequence" >> $scriptlog 2>&1
    72    setstatus "start" >> $scriptlog 2>&1
     68   setstatus "start"
    7369
    74    check2=`root -q -b $macrospath/writesequencefile.C\($sequence\,$telnum\,"\"$sequpath\""\) | tee $writesequencefilelog | intgrep`
    75    case $check2 in
    76       1)   echo " check2=$check2 -> everything ok " >> $scriptlog 2>&1
    77            printprocesslog "INFO sequence file successfully written for sequence $sequence"
     70   check1=`root -q -b $macrospath/writesequencefile.C\($sequence\,$telnum\,"\"$sequpath\""\) | tee $writesequencefilelog | intgrep`
     71   case $check1 in
     72      1)   printprocesslog "INFO sequence file successfully written for sequence $sequence (check1=$check1)"
    7873           ;;
    79       0)   echo " check2=$check2 -> no connection to db -> continue..." >> $scriptlog 2>&1
    80            printprocesslog "WARN connection to DB failed"
     74      0)   printprocesslog "WARN connection to DB failed (check1=$check1)"
    8175           check="no"
    8276           ;;
    83       *)   echo " check2=$check2 -> ERROR -> step has to be repeated" >> $scriptlog 2>&1
    84            printprocesslog "ERROR $program.C failed for sequence $sequence"
     77      *)   printprocesslog "ERROR $program.C failed for sequence $sequence (check1=$check1)"
    8578           com=$Fwritesequfile
    86            check=$check2
     79           check=$check1
    8780           ;;
    8881   esac
    8982   
    90    setstatus "stop" >> $scriptlog 2>&1
     83   setstatus "stop"
    9184done
    9285
    93 finish >> $scriptlog 2>&1
     86finish
    9487
Note: See TracChangeset for help on using the changeset viewer.