WikiPrint - from Polar Technologies

framework4g.conf file

The framework4g.conf file is read by wrf4g_framework to manage the WRF4G framework. It is located under $WRF4G_LOCATION/etc and has two sections, Database and Computing Resources.


WRF4G uses a MySQL database in order to keep track of the experiments. For that reason, WRF4G provides a 5.5-x86_64 distribution of MySQL under $WRF4G_LOCATION/opt/ directory. Also, you can use another MySQL changing WRF4G_DB_LOCAL variable.

You should modify the database password and WRF4G_DB_PASSWD variable after starting wrf4g_framework. To do that, you can execute:
echo "SET PASSWORD FOR 'wrf4guser'@'%' = PASSWORD('newpassword');" | mysql -P 13306 -u wrf4guser -h -p

0 indicates that you will use an external DB and the local database included in WRF4G distribution. If you want to use an external database, you will have to import WRF4GDB? table in your MySQL.
Computer where the DB is running. If WRF4G_DB_LOCAL=1, WRF4G_DB_HOST has to be the name of the computer where WRF4G is running.
Port where mysql DB is listening.
Credentials to access DB
Name of the WRF4G DB

Computing Resources

WRF4G uses DRM4G in order to configure computing resources. Using that tool, users are able to access to different Distributed Resource Managements (DRM) such as:

# Syntax
#   '#' Comments
# This section contains one resource per line, with format:
#   resource = attributes
#   ...  ...
#   resource = attributes
#   where:
#   * resource  : It is the name of the computing resource.
#   * attributes: They are the static attributes of the computing resource. The syntax is:
#        <scheme>://<username>@<host:port>?<query>
#        -scheme: URL schemes available are "ssh" and "local".
#            * ssh:   In order to connect to remote resource via SSH
#            * local: In order to use a local resource
#        -username: user name on the resource
#        -host: host name
#        -port: host port to connect to. By DEFAULT is 22
#        -query: contains additional information of computing resources. The query string syntax is:
#            * key1=value1;key2=value2;key3=value3
#            Variable options:
#               LRMS_TYPE    (mandatory)    : Type of LRMS system [pbs | sge | fork | slurm ]
#               NODECOUNT    (mandatory)    : Maximum number of job slots for a resource
#               QUEUE_NAME   (mandatory)    : Queue name to configure. It is mandatory except for "LRMS_TYPE=fork"
#               SSH_KEY_FILE (optional)     : Defines the key file for "ssh" connection.
#                                             By DEFAULT is ~/.ssh/id_rsa
#               PROJECT      (optional)     : Specifies the project which the jobs are assigned.
#                                             It is only optional for SGE and PBS
#               PARALLEL_TAG (optional)     : Defines the parallel environments available for SGE
#               TEMP_DIR     (optional)     : Temporary directory used by DRM4G on the resource to temporarily store data
#                                             By DEFAULT is $HOME. TEMP_DIR path must be absolute
#               RUN_DIR      (optional)     : Temporary directory used to run WRF Model on the resource
#                                             By DEFAULT is $HOME. RUN_DIR path must be absolute
# Examples
# resource            = <scheme>://<username>@<host>?<query>
# FORK_resource       = local://localhost?LRMS_TYPE=fork;NODECOUNT=1
# PBS_cluster         = local://localhost?LRMS_TYPE=pbs;QUEUE_NAME=estadistica;NODECOUNT=8
# SGE_cluster         = local://localhost?LRMS_TYPE=sge;QUEUE_NAME=meteo;PROJECT=l.project;NODECOUNT=16;PARALLEL_TAG=mpi
# remote_PBS_cluster  = ssh://user@hostname_submitting_machine?LRMS_TYPE=pbs;SSH_KEY_FILE=~/.ssh/id_rsa;QUEUE_NAME=short;NODECOUNT=16
# remote_SGE_cluster  = ssh://user@hostname_submitting_machine?LRMS_TYPE=sge;QUEUE_NAME=meteo;SSH_KEY_FILE=~/.ssh/id_dsa;NODECOUNT=64
# remote_FORK_cluster = ssh://user@hostname_submitting_machine?LRMS_TYPE=fork;NODECOUNT=1

# By default, WRF4G is going to use the local machine as FORK system
mycomputer   = local://localhost?LRMS_TYPE=fork;NODECOUNT=1

More information regarding how to add resources on DRM4G.

If you want to configure Grid Resources, you have to see WRF4G Grid Configuration.