- Timestamp:
- 12/01/08 10:48:20 (16 years ago)
- Location:
- trunk/MagicSoft/Mars
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/Changelog
r9181 r9183 18 18 19 19 -*-*- END OF LINE -*-*- 20 21 2008/12/01 Daniela Dorner 22 23 * datacenter/scripts/runcorsika: 24 - removed not needed query 25 26 * datacenter/scripts/sourcefile: 27 - added check if script is executed with the full path 28 - added check if rc-files are existing 29 30 31 20 32 2008/11/28 Thomas Bretz 21 33 -
trunk/MagicSoft/Mars/datacenter/scripts/runcorsika
r9177 r9183 40 40 echo "RUNNR "$corsikarunno 41 41 echo "PRMPAR "$primparticle 42 query="SELECT fEnergyMin, fEnergyMax FROM MCCorsikaRunData where fCorsikaRunNumber="$corsikarunno43 42 echo "ERANGE "$erange 44 43 echo "EVTNR 1" -
trunk/MagicSoft/Mars/datacenter/scripts/sourcefile
r9165 r9183 31 31 # 32 32 33 # check if script has been started with absolute path 34 if ! dirname $0 | grep -E '^/' >/dev/null 2>&1 35 then 36 echo "Please start your script with an absolute path." 37 exit 38 fi 39 33 40 source `dirname $0`/setup 34 41 … … 67 74 68 75 makedir $lockpath 76 77 78 # function to provide proper logging in a single logfile ($processlog) 79 function printprocesslog 80 { 81 makedir $processlogpath 82 echo `date +%F\ %T`" "`whoami`"@"$HOSTNAME" "`basename $0`"["$$"] "$@ >> $processlog 83 } 84 85 # function to exit a script properly 86 function finish() 87 { 88 if ! [ "$lockfile" = "" ] && ls $lockfile >/dev/null 2>&1 89 then 90 rm -v $lockfile 91 fi 92 date 93 printprocesslog "INFO finished $0" 94 exit 95 } 96 69 97 70 98 # set checkvalue to ok at the beginning of the scripts … … 112 140 jmscriptlog=$runlogpath/jobmanager`date +%F`.log 113 141 steps=$mars/resources/steps.rc 142 if ! ls $steps >/dev/null 143 then 144 echo "Can't find steps.rc ($steps)" 145 finish 146 fi 114 147 sqlrc=$mars/sql.rc 148 if ! ls $sqlrc >/dev/null 149 then 150 echo "Can't find sql.rc ($sqlrc)" 151 finish 152 fi 115 153 # resetting values 116 154 pno=0 … … 129 167 # in the following the functions, which are needed by several scripts, are 130 168 # defined 131 132 function printprocesslog133 {134 makedir $processlogpath135 echo `date +%F\ %T`" "`whoami`"@"$HOSTNAME" "`basename $0`"["$$"] "$@ >> $processlog136 }137 138 # function to exit a script properly139 function finish()140 {141 if ! [ "$lockfile" = "" ] && ls $lockfile >/dev/null 2>&1142 then143 rm -v $lockfile144 fi145 date146 printprocesslog "INFO finished $0"147 exit148 }149 169 150 170 # function to do continue in a loop and produce according logging
Note:
See TracChangeset
for help on using the changeset viewer.