Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This page contains a guide for building and using OpenIFS 48r1 in a linux based container using Docker. 

The instructions presented assume that docker is installed on the system of interest. If docker is not installed please speak with local system administration to find out if installation is permitted and how to do it. The specifics of this page have been tested with docker desktop on ubuntu 22.04 and Apple Macbook M1

While this page focuses on the containerised installation, the details presented can be used , particularly the list of libraries to install, can be used as a recipe for the underlying dependencies required to install and run OpenIFS 48r1 on a linux system.

...

Code Block
languagebash
themeMidnight
# download the openifs-48r1.tar.gz model package from https://sites.ecmwf.int/openifs/openifs-data/src/48r1/openifs-48r1.tar.gz to <openifs-docker-build-dir> and untar :
tar -xvzf openifs-48r1.tar.gz

Further, if the SCM is required, then Then also download the SCM package to <openifs-docker-build-dir> from https://sites.ecmwf.int/openifs/openifs-data/scm/48r1/scm_openifs_48r1.tar.gz . 

Code Block
languagebash
themeMidnight
# download the scm_openifs_48r1.tar.gz https://sites.ecmwf.int/openifs/openifs-data/scm/48r1/scm_openifs_48r1.tar.gz to <openifs-docker-build-dir> and untar :
tar -xzvf scm_openifs_48r1.tar.gz

At present, the SCM package is required for the build of the container.

Once OpenIFS 48r1 has and the SCM package have been extracted to your your <openifs-docker-build-dir> ,  then copy the Dockerfile from the release to <openifs-docker-build-dir> 

...

Code Block
languagebash
themeMidnight
openifs@d1bd89ccc47f:~/openifs-48r1$ $OIFS_TEST/openifs-test.sh -cbt -j 2 --arch=""

where :

-c   creates source directory in $OIFS_HOME, which is used to bring all the sources, e.g. ifs-source, ifs-test and any packages in the bundle (ecbuild, eccodes etc.), together in preparation for the build

...

  • 21 3-D OpenIFS forecast-only tests with and without chemistry
  • 1 SCM test (based on TWP-ICE)

-j is an optional argument that allows the user to define the number of threads used to create and build openifs, with the above example using 2 threads. It should be noted that 

  • If -j is not supplied as a command line argument, as in the above example, the number of threads will default to 8 threads, which can be problematic for older and lower spec systems. For example, it will not work with a 4 core intel m3. The above example uses 2 threads, which should work on most systems.
  • The number of threads can be increased to speed up the build step, but how much the number of threads can be increased to will depend on the system spec. Hence, please speak the local system administration for guidance about appropriate settings. 

--arch="" means no arch file is required because all the libraries and paths have been set-up locally in the docker container. 

...