- Timestamp:
- 02/19/09 21:22:19 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/datacenter/scripts/writedatasetfiles
r9113 r9355 41 41 column=fDataSetFileWritten 42 42 43 scriptlog=$runlogpath/$program-$datetime.log44 date >> $scriptlog 2>&145 46 43 # check if script is already running 47 44 lockfile=$lockpath/lock-$program.txt 48 checklock >> $scriptlog 2>&145 checklock 49 46 50 47 # get todo list 51 gettodo >> $scriptlog 2>&148 gettodo 52 49 53 50 cd $mars … … 56 53 do 57 54 dataset=${primaries[$s]} 58 echo "writing dataset file for dataset $dataset..." >> $scriptlog 2>&159 55 printprocesslog "INFO writing datasetfile for dataset $dataset" 60 56 no=`printf %08d $dataset | cut -c 0-5` 61 57 no2=`printf %08d $dataset` 62 58 datasetpathcpl=$datasetpath/$no 63 makedir $datasetpathcpl >> $scriptlog 2>&159 makedir $datasetpathcpl 64 60 writedatasetfilelogpath=$logpath/$program/$no 65 makedir $writedatasetfilelogpath >> $scriptlog 2>&161 makedir $writedatasetfilelogpath 66 62 logfile=$writedatasetfilelogpath/$program-$no2.log 67 63 68 setstatus "start" >> $scriptlog 2>&164 setstatus "start" 69 65 70 66 check1=`root -q -b $macrospath/writedatasetfile.C+\($dataset\,\""$datasetpathcpl\""\) | tee $logfile | intgrep` 71 67 72 68 case $check1 in 73 1) echo " check1=$check1 -> everything ok" >> $scriptlog 2>&1 74 printprocesslog "INFO wrote datasetfile for dataset $dataset successfully" 69 1) printprocesslog "INFO wrote datasetfile for dataset $dataset successfully (check1=$check1)" 75 70 ;; 76 0) echo " check1=$check1 -> no connection to db -> continue..." >> $scriptlog 2>&1 77 printprocesslog "WARN connection to DB failed" 71 0) printprocesslog "WARN connection to DB failed (check1=$check1)" 78 72 check="no" 79 73 ;; 80 *) echo " check1=$check1 -> ERROR " >> $scriptlog 2>&1 81 printprocesslog "ERROR writedatasetfile.C failed" 74 *) printprocesslog "ERROR writedatasetfile.C failed (check1=$check1)" 82 75 com=$Fwritedatasetfile 83 76 check=$check1 … … 85 78 esac 86 79 87 setstatus "stop" >> $scriptlog 2>&180 setstatus "stop" 88 81 done 89 82 90 finish >> $scriptlog 2>&183 finish 91 84
Note:
See TracChangeset
for help on using the changeset viewer.