Change-Id: Icafd7505b59dc0bf3673c655ceff93c3fefb5176 Former-commit-id:153619e7ff
[formerly a64386381a2543f3a01e418abc0ec36cc317fbeb] Former-commit-id:de340cde75
This commit is contained in:
parent
c5cb33d841
commit
6914d33292
2 changed files with 57 additions and 9 deletions
|
@ -89,7 +89,7 @@ class Procedure (SmartScript.SmartScript):
|
||||||
("How Long Do You Want To Run NWPS:" , 102, "scale", [12, 102], 3),
|
("How Long Do You Want To Run NWPS:" , 102, "scale", [12, 102], 3),
|
||||||
#("NWPS Model Winds:", "ForecastWindGrids", "radio", ["ForecastWindGrids"]),
|
#("NWPS Model Winds:", "ForecastWindGrids", "radio", ["ForecastWindGrids"]),
|
||||||
("Model Start Time:", buttonList[4], "radio", buttonList),
|
("Model Start Time:", buttonList[4], "radio", buttonList),
|
||||||
("Local or NCEP:", "Local", "radio", ["Local","NCEP"]),
|
("Local, NCEP, or Both:", "Both", "radio", ["Local","NCEP","Both"]),
|
||||||
("Model Core:", "SWAN", "radio", ["SWAN","NWW","UNSWAN"]),
|
("Model Core:", "SWAN", "radio", ["SWAN","NWW","UNSWAN"]),
|
||||||
("Send Output to Web:", "Yes", "radio", ["Yes","No"]),
|
("Send Output to Web:", "Yes", "radio", ["Yes","No"]),
|
||||||
("Plot Output Only (No Web):", "No", "radio", ["Yes","No"]),
|
("Plot Output Only (No Web):", "No", "radio", ["Yes","No"]),
|
||||||
|
@ -112,7 +112,7 @@ class Procedure (SmartScript.SmartScript):
|
||||||
fcst_length = processVarList.varDict()["How Long Do You Want To Run NWPS:"]
|
fcst_length = processVarList.varDict()["How Long Do You Want To Run NWPS:"]
|
||||||
wind="ForecastWindGrids"
|
wind="ForecastWindGrids"
|
||||||
modelstarttime = processVarList.varDict()["Model Start Time:"]
|
modelstarttime = processVarList.varDict()["Model Start Time:"]
|
||||||
wheretorun = processVarList.varDict()["Local or NCEP:"]
|
wheretorun = processVarList.varDict()["Local, NCEP, or Both:"]
|
||||||
model = processVarList.varDict()["Model Core:"]
|
model = processVarList.varDict()["Model Core:"]
|
||||||
web = processVarList.varDict()["Send Output to Web:"]
|
web = processVarList.varDict()["Send Output to Web:"]
|
||||||
plot = processVarList.varDict()["Plot Output Only (No Web):"]
|
plot = processVarList.varDict()["Plot Output Only (No Web):"]
|
||||||
|
|
|
@ -1,6 +1,14 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
NWPSLOCAL="/awips2/GFESuite/nwps"
|
NWPSLOCAL="/awips2/GFESuite/nwps"
|
||||||
|
#
|
||||||
|
# The following two variables need to be set to your regional LDM. This is the same
|
||||||
|
# ldm servers you can reach from your ldad. If you do not know this info contact your
|
||||||
|
# regional folks. This is how the input files for NWPS run requests will be routed to
|
||||||
|
# NCO/WCOSS when that option is chosen from the GUI.
|
||||||
|
#
|
||||||
|
LDMSERVER1="srh-ls-cpnrs1.srh.noaa.gov"
|
||||||
|
LDMSERVER2="srh-ls-cpnrs2.srh.noaa.gov"
|
||||||
|
|
||||||
if [ ! -e ${NWPSLOCAL}/input ]
|
if [ ! -e ${NWPSLOCAL}/input ]
|
||||||
then
|
then
|
||||||
|
@ -187,15 +195,55 @@ touch $flagfile
|
||||||
chmod 666 $textfile.gz
|
chmod 666 $textfile.gz
|
||||||
chmod 666 $flagfile
|
chmod 666 $flagfile
|
||||||
|
|
||||||
if [ $WHERETORUN == "Local" ]
|
if [ $WHERETORUN == "Both" ]
|
||||||
then
|
then
|
||||||
|
|
||||||
logit " "
|
logit " "
|
||||||
logit "RUNNING IN WORKSTATION"
|
logit "RUNNING IN WORKSTATION"
|
||||||
logit " "
|
logit " "
|
||||||
logit "### ROUTING 3 WIND FILES NEEDED BY SWAN THROUGH LDAD TO LOCAL WORKSTATION:"
|
logit "### ROUTING 3 WIND FILES NEEDED BY SWAN THROUGH LDAD TO LOCAL WORKSTATION:"
|
||||||
|
|
||||||
ssh ldad@ls1 mkdir -p ${DIR}
|
ssh ldad@ls1 mkdir -p ${DIR}
|
||||||
|
scp ${SCPARGS} $Output_File ldad@ls1:${DIR} | tee -a $logfile
|
||||||
|
scp ${SCPARGS} $textfile.gz ldad@ls1:${DIR} | tee -a $logfile
|
||||||
|
scp ${SCPARGS} $flagfile ldad@ls1:${DIR} | tee -a $logfile
|
||||||
|
|
||||||
|
logit " "
|
||||||
|
#########################################################################
|
||||||
|
logit "##################################################################"
|
||||||
|
logit "### SENDING WIND FILES TO NWPS SYSTEM VIA LDAD TO TRIGGER NEW RUN"
|
||||||
|
logit "### Start Time is: $(date)"
|
||||||
|
logit "##################################################################"
|
||||||
|
logit " "
|
||||||
|
|
||||||
|
logit "Runtime Parameters are: $RUNLEN:$WNA:$NEST:$GS:$WINDS:$WEB:$PLOT:$DELTAC:$HOTSTART:$WATERLEVELS:$CORE:$EXCD"
|
||||||
|
|
||||||
|
ssh ${SSHARGS} ldad@ls1 echo "$RUNLEN:$WNA:$NEST:$GS:$WINDS:$WEB:$PLOT:$DELTAC:$HOTSTART:$WATERLEVELS:$CORE:$EXCD > /data/ldad/nwps/input/inp_args" 2>&1 | tee -a $logfile
|
||||||
|
|
||||||
|
logit " "
|
||||||
|
logit "RUNNING IN NCEP"
|
||||||
|
logit " "
|
||||||
|
echo "$RUNLEN:$WNA:$NEST:$GS:$WINDS:$WEB:$PLOT:$DELTAC:$HOTSTART:$WATERLEVELS:$CORE:$EXCD" > ${NWPSLOCAL}/wcoss/${siteid}_inp_args.ctl
|
||||||
|
|
||||||
|
chmod 666 ${NWPSLOCAL}/wcoss/${siteid}_inp_args.ctl
|
||||||
|
|
||||||
|
cd ${NWPSLOCAL}/wcoss/
|
||||||
|
NWPSWINDGRID="NWPSWINDGRID_${siteid}_$(date +%Y%m%d%H%M)_$$.tar.gz"
|
||||||
|
tar cvfz ${NWPSWINDGRID} ${siteid}_inp_args.ctl ${siteid}_domain_setup.cfg ${wcoss_textfile}
|
||||||
|
scp ${NWPSWINDGRID} ldad@ls1:/tmp/
|
||||||
|
ssh ldad@ls1 "cd /tmp; /usr/local/ldm/bin/ldmsend -v -h ${LDMSERVER1} -f EXP ${NWPSWINDGRID}" 2>&1 | tee -a $logfile
|
||||||
|
ssh ldad@ls1 "cd /tmp; /usr/local/ldm/bin/ldmsend -v -h ${LDMSERVER2} -f EXP ${NWPSWINDGRID}" 2>&1 | tee -a $logfile
|
||||||
|
ssh ldad@ls1 rm -fv /tmp/${NWPSWINDGRID}
|
||||||
|
|
||||||
|
elif [ $WHERETORUN == "Local" ]
|
||||||
|
then
|
||||||
|
|
||||||
|
logit " "
|
||||||
|
logit "RUNNING IN WORKSTATION"
|
||||||
|
logit " "
|
||||||
|
logit "### ROUTING 3 WIND FILES NEEDED BY SWAN THROUGH LDAD TO LOCAL WORKSTATION:"
|
||||||
|
|
||||||
|
ssh ldad@ls1 mkdir -p ${DIR}
|
||||||
scp ${SCPARGS} $Output_File ldad@ls1:${DIR} | tee -a $logfile
|
scp ${SCPARGS} $Output_File ldad@ls1:${DIR} | tee -a $logfile
|
||||||
scp ${SCPARGS} $textfile.gz ldad@ls1:${DIR} | tee -a $logfile
|
scp ${SCPARGS} $textfile.gz ldad@ls1:${DIR} | tee -a $logfile
|
||||||
scp ${SCPARGS} $flagfile ldad@ls1:${DIR} | tee -a $logfile
|
scp ${SCPARGS} $flagfile ldad@ls1:${DIR} | tee -a $logfile
|
||||||
|
@ -215,7 +263,7 @@ then
|
||||||
else
|
else
|
||||||
|
|
||||||
logit " "
|
logit " "
|
||||||
logit "RUNNING IN NCEP"
|
logit "RUNNING IN NCEP"
|
||||||
logit " "
|
logit " "
|
||||||
echo "$RUNLEN:$WNA:$NEST:$GS:$WINDS:$WEB:$PLOT:$DELTAC:$HOTSTART:$WATERLEVELS:$CORE:$EXCD" > ${NWPSLOCAL}/wcoss/${siteid}_inp_args.ctl
|
echo "$RUNLEN:$WNA:$NEST:$GS:$WINDS:$WEB:$PLOT:$DELTAC:$HOTSTART:$WATERLEVELS:$CORE:$EXCD" > ${NWPSLOCAL}/wcoss/${siteid}_inp_args.ctl
|
||||||
|
|
||||||
|
@ -224,9 +272,9 @@ else
|
||||||
cd ${NWPSLOCAL}/wcoss/
|
cd ${NWPSLOCAL}/wcoss/
|
||||||
NWPSWINDGRID="NWPSWINDGRID_${siteid}_$(date +%Y%m%d%H%M)_$$.tar.gz"
|
NWPSWINDGRID="NWPSWINDGRID_${siteid}_$(date +%Y%m%d%H%M)_$$.tar.gz"
|
||||||
tar cvfz ${NWPSWINDGRID} ${siteid}_inp_args.ctl ${siteid}_domain_setup.cfg ${wcoss_textfile}
|
tar cvfz ${NWPSWINDGRID} ${siteid}_inp_args.ctl ${siteid}_domain_setup.cfg ${wcoss_textfile}
|
||||||
scp ${NWPSWINDGRID} ldad@ls1:/tmp/
|
scp ${NWPSWINDGRID} ldad@ls1:/tmp/
|
||||||
ssh ldad@ls1 "cd /tmp; /usr/local/ldm/bin/ldmsend -v -h srh-ls-cpnrs1.srh.noaa.gov -f EXP ${NWPSWINDGRID}" 2>&1 | tee -a $logfile
|
ssh ldad@ls1 "cd /tmp; /usr/local/ldm/bin/ldmsend -v -h ${LDMSERVER1} -f EXP ${NWPSWINDGRID}" 2>&1 | tee -a $logfile
|
||||||
ssh ldad@ls1 "cd /tmp; /usr/local/ldm/bin/ldmsend -v -h srh-ls-cpnrs2.srh.noaa.gov -f EXP ${NWPSWINDGRID}" 2>&1 | tee -a $logfile
|
ssh ldad@ls1 "cd /tmp; /usr/local/ldm/bin/ldmsend -v -h ${LDMSERVER2} -f EXP ${NWPSWINDGRID}" 2>&1 | tee -a $logfile
|
||||||
ssh ldad@ls1 rm -fv /tmp/${NWPSWINDGRID}
|
ssh ldad@ls1 rm -fv /tmp/${NWPSWINDGRID}
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Add table
Reference in a new issue