source: flex_extract.git/run/jobscripts/joboper.ksh @ d4696e0

ctbtodev
Last change on this file since d4696e0 was d4696e0, checked in by Anne Philipp <anne.philipp@…>, 5 years ago

bugfix retrievement with basetime parameter

  • Property mode set to 100644
File size: 3.1 KB
Line 
1#!/bin/ksh
2
3# ON ECGB:
4# start with ecaccess-job-submit -queueName ecgb NAME_OF_THIS_FILE  on gateway server
5# start with sbatch NAME_OF_THIS_FILE directly on machine
6
7#SBATCH --workdir=/scratch/ms/at/km4a
8#SBATCH --qos=normal
9#SBATCH --job-name=flex_ecmwf
10#SBATCH --output=flex_ecmwf.%j.out
11#SBATCH --error=flex_ecmwf.%j.out
12#SBATCH --mail-type=FAIL
13#SBATCH --time=12:00:00
14
15## CRAY specific batch requests
16##PBS -N flex_ecmwf
17##PBS -q np
18##PBS -S /usr/bin/ksh
19## -o /scratch/ms/at/km4a/flex_ecmwf.${PBS_JOBID}.out
20## job output is in .ecaccess_DO_NOT_REMOVE
21##PBS -j oe
22##PBS -V
23##PBS -l EC_threads_per_task=24
24##PBS -l EC_memory_per_task=32000MB
25
26set -x
27export VERSION=7.1
28case ${HOST} in
29  *ecg*)
30  module load python
31  module unload grib_api
32  module unload eccodes
33  module load eccodes
34  module unload emos
35  module load emos/455-r64
36  export PATH=${PATH}:${HOME}/flex_extract_v7.1/source/python
37  ;;
38  *cca*)
39  module switch PrgEnv-cray PrgEnv-intel
40  module load eccodes
41  module load emos
42  module load python
43  export SCRATCH=${TMPDIR}
44  export PATH=${PATH}:${HOME}/flex_extract_v7.1/source/python
45  ;;
46esac
47
48cd ${SCRATCH}
49mkdir -p python$$
50cd python$$
51
52export CONTROL=CONTROL
53
54cat >${CONTROL}<<EOF
55accmaxstep 12
56acctime 00/12
57acctype FC
58accuracy 24
59addpar /186/187/188/235/139/39
60area 90.0/-179.0/-90.0/180.0
61base_time ${MSJ_BASETIME}
62basetime 0
63controlfile CONTROL_OPS
64cwc 1
65dataset None
66date_chunk 3
67debug 1
68destination annep@genericSftp
69dpdeta 1
70dtime 3
71ecapi None
72ecfsdir ectmp:/${USER}/ecops
73ecgid at
74ecstorage 0
75ectrans 1
76ecuid km4a
77end_date ${MSJ_YEAR}${MSJ_MONTH}${MSJ_DAY}
78eta 1
79etadiff 0
80etapar 77
81expver 1
82format GRIB2
83gateway srvx8.img.univie.ac.at
84gauss 0
85gaussian
86grib2flexpart 0
87grid 1.0/1.0
88inputdir /raid60/nas/tmc/Anne/Interpolation/flexextract/flex_extract_v7.1/run/workspace
89install_target None
90job_chunk 3
91job_template job.temp
92left -179000
93level 137
94levelist 130/to/137
95logicals gauss omega omegadiff eta etadiff dpdeta cwc wrf grib2flexpart ecstorage ectrans debug request public purefc rrint
96lower -90000
97mailfail ${USER}
98mailops ${USER}
99makefile Makefile.gfortran
100marsclass OD
101maxstep 11
102number OFF
103omega 0
104omegadiff 0
105outputdir /raid60/nas/tmc/Anne/Interpolation/flexextract/flex_extract_v7.1/run/workspace
106prefix EN
107public 0
108purefc 0
109queue ecgate
110request 2
111resol 159
112right 180000
113rrint 0
114smooth 0
115start_date ${MSJ_YEAR}${MSJ_MONTH}${MSJ_DAY}
116step 00 01 02 03 04 05 06 07 08 09 10 11 00 01 02 03 04 05 06 07 08 09 10 11
117stream OPER
118time 00 00 00 00 00 00 00 00 00 00 00 00 12 12 12 12 12 12 12 12 12 12 12 12
119type AN FC FC FC FC FC FC FC FC FC FC FC AN FC FC FC FC FC FC FC FC FC FC FC
120upper 90000
121wrf 0
122
123EOF
124
125
126submit.py --controlfile=${CONTROL} --inputdir=./work --outputdir=./work 1> prot 2>&1
127
128if [ $? -eq 0 ] ; then
129  l=0
130  for muser in `grep -i MAILOPS ${CONTROL}`; do
131      if [ ${l} -gt 0 ] ; then 
132         mail -s flex.${HOST}.$$ ${muser} <prot
133      fi
134      l=$((${l}+1))
135  done
136else
137  l=0
138  for muser in `grep -i MAILFAIL ${CONTROL}`; do
139      if [ ${l} -gt 0 ] ; then 
140         mail -s "ERROR! flex.${HOST}.$$" ${muser} <prot
141      fi
142      l=$((${l}+1))
143  done
144fi
145
Note: See TracBrowser for help on using the repository browser.
hosted by ZAMG