Page 1 of 1

WRF-EMS v2 NMM autonest cannot go over 99h - solution here

Posted: Fri Aug 21, 2009 7:28 pm
by meteoadriatic
OK, let's start!

WRF-NMM autonest routine in WRF-EMS v2 is great but has one bug that prevents running nests over 99 hours. It won't copy necessary gribs beyond 99h to input directory for initializing child domain. I needed runs past 99h so I had to find workaround for this issue.

As I'm not programmer I couldn't find where bug is in autonest routine scripts so I created VERY dirty fix, not nice at all but it works (please, don'l laugh at some lines in script, I had not inspiration to find better way to do).

Here is script that do the job and inside it is explained how to use it. If you have any questions about it feel free to ask.

Code: Select all

#!/bin/bash
# This little script fixes WRFEMS V2 bug that prevents
# NMM domain nesting if user requests run over 99 hours
#
# Yu will need to run this script in aptly time. My advice is
# to edit /usr1/wrf/strc/wrf_autorun.pl and between lines
# 405 and 406 add this line:
# 
# system "sh /home/wrf/fix_autonest.sh &";
# 
# Of course, then you should place this script into
# /home/wrf/fix_autonest.sh
#
# Feel free to find and fix the root of the autonest routine problem,
# because this script is just very ugly hack that makes it work.
#
# NOTE: because of way this fix works, you will be faced
# with timeout in running your model between every nest.
# Timeout will equal time specified in
# /usr1/wrf/runs/domainname/conf/wrf_autorun/wrf_autorun.conf
# at parameter SLEEP = 300
# You might want to change this value to some shorter time.
# Do that change only for your nested domains, not for MOAD!
#
# Adapt directory paths to yours!
#
# contact: meteoadriatic m*****y gmail.com

#########################################################################
# Script below this line


# MOAD -> First level nest

# Rename files so that EMS routines can find them
cd /usr1/wrf/runs/eur36/wrfpost/grib
rename GrbF1 GrbF01 *
# Make sure script really goes out of these dirs to avoid possible mess
mkdir /home/wrf/kW45gEckh432
cd /home/wrf/kW45gEckh432


# First level nest -> Second level nest

# Rename files so that EMS routines can find them
cd /usr1/wrf/runs/hrv12/wrfpost/grib
rename GrbF1 GrbF01 *
# Make sure script really goes out of these dirs to avoid possible mess
cd /home/wrf/kW45gEckh432

# Remove all traces left behind my existance :)
rm -rf /home/wrf/kW45gEckh432