Ignore:
Timestamp:
10/27/10 17:48:15 (14 years ago)
Author:
Daniela Dorner
Message:
lock in db instead of lockfile
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Mars/datacenter/scripts/runstar_mc

    r9611 r10041  
    3636
    3737# get sequence #
    38 gettodo "1"
    39 sequence=${primaries[0]}
    40 cereskey=${primaries[1]}
    41 
    42 # lock sequ for cal
    43 lockfile=$lockpath/lock-$step-$sequence-$cereskey.txt
    44 checklock
     38numchanged=0
     39while (( 0 < 21 ))
     40do
     41   if ! [ $numchanged -eq 1 ]
     42   then
     43      if ! [ "$sequence" = "" ] && ! [ "$cereskey" = "" ]
     44      then
     45         printprocesslog "INFO $program for sequence $sequence cereskey $cereskey is already running => request new number "
     46      fi
     47      gettodo "1"
     48      sequence=${primaries[0]}
     49      cereskey=${primaries[1]}
     50      if [ "$sequence" = "" ] || [ "$cereskey" = "" ]
     51      then
     52         printprocesslog "INFO nothing to do for $program "
     53      fi
     54   else
     55      printprocesslog "INFO starting $program for sequence $sequence cereskey $cereskey"
     56      break
     57   fi
     58   setstatus "start"
     59done
    4560
    4661cd $mars
    4762
    4863# run calibration for sequence
    49 printprocesslog "INFO starting $program for sequence $sequence cereskey $cereskey"
    5064
    5165# define files and paths
     
    5569log=$outpath/$program`printf %08d $sequence`
    5670inpath=$mcpath/callisto/`printf %03d $cereskey`/`printf %08d $sequence | cut -c 1-4`/`printf %08d $sequence | cut -c 5-8`
    57 
    58 setstatus "start"
    5971
    6072command="./star -b -q -v4 -f --ind=$inpath --out=$outpath --log=$log.log --html=$log.html $sequfile"
Note: See TracChangeset for help on using the changeset viewer.