forked from NOAA-EMC/CFSv2
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathJCFS_CDAS_LANDANAL
More file actions
executable file
·102 lines (80 loc) · 2.94 KB
/
JCFS_CDAS_LANDANAL
File metadata and controls
executable file
·102 lines (80 loc) · 2.94 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
#!/bin/ksh
set -xa
#####################################################################################
# Run config file to get input parameters
# This config file should define the following variables
# DATA_IN: Location of working directory, default to /tmpnwprd1
# DEV_ECF: If the job is to be running using SMS, default to YES
# SENDDBN: Set to NO for developers, default to YES
# COM_IN: Directory for input files, default to /com/$NET/${envir}
# COM_OUT: Directory for output file, default to /com/$NET/${envir}
# gespath: Directory for the guess or restart files, default to /nwges/${envir}
#####################################################################################
####################################
# Specify NET and RUN Name and model
####################################
export NET=cfs
export RUN=cdas
export RUN1=cdas1
export host=${host:-`hostname | cut -c1`}
export jlogfile=${jlogfile:-/dev/null}
date
export PS4='$SECONDS + '
# #############################################
# SETUP CLDAS PREP PROCESSING VARIABLES
# ##############################################
##########################################################
# obtain unique process id (pid) and make temp directory
##########################################################
export pid=$$
export DATA=$DATAROOT/$job.$pid
mkdir -p $DATA
cd $DATA
####################################
# Determine Job Output Name on System
####################################
export pgmout="OUTPUT.${pid}"
export pgmerr=errfile
export cycle=t${cyc}z
##############################
# Run setpdy and initialize PDY variables
##############################
sh setpdy.sh
. ./PDY
export CDATE=${PDY}${cyc}
##########################################################
# define cfs directories/scripts/executables
##########################################################
export EXECcfs=$HOMEcfs/exec
export PARMcfs=$HOMEcfs/parm
export USHcfs=$HOMEcfs/ush
export FIXcfs=$HOMEcfs/fix
##############################################
# Define COM directories
##############################################
export COMROT=$COMROOT/${NET}/${envir}
export COMIN=$COMROOT/${NET}/${envir}/${RUN}.${PDY}
export COMOUT=$COMROOT/${NET}/${envir}/${RUN}.${PDY}
mkdir -m775 -p $COMOUT
##############################################
# Define GES directories
##############################################
export gespath=${gespath:-${GESROOT}/$envir}
export GESdir=$gespath/cdas.$PDY
mkdir -m 775 -p $GESdir
export RESDIR=${RESDIR:-$GESdir}
mkdir -p $RESDIR
env
#############################################################
# execute the script
${CLDASSH:-$HOMEcfs/scripts/excfs_cdas_gldas.sh.ecf}
#############################################################
cat $pgmout
msg="ENDED NORMALLY."
postmsg "$jlogfile" "$msg"
########################################
# Remove the Temporary working directory
########################################
cd $DATAROOT
if [ ${KEEPDATA:-NO} = NO ] ; then rm -rf $DATA ; fi
date