Frequently Asked Questions

Is there any performance degradation when running via Docker? No performance penalties are expected. On Linux, OpenFOAM inside
Docker should run as fast as natively compiled code. On Windows and
Mac OS X there may be a slight performance penalty associated with
I/O.

How do I check if the OpenFOAM image has been downloaded correctly?Type the command

If you receive an error message about not being able to contact the Docker
daemon check that

the Docker daemon is started at boot time

the user account is in the group ‘docker’

Where are my files? The user files inside Docker are visible (i.e. mounted) in your home area and
can be operated on just like any other file.

Why doesn’t paraFoam display?

Make sure that your machine’s software is fully up-to-date. See
if you can start a simple X-windows, non-graphics program, e.g.:
xterm If this does not come up there may be a problem with the
xhost access to the host screen. This is one of the steps inside the
startOpenFOAM script.

An alternative remedy is to install the native ParaView version
for your system, and use the built-in OpenFOAM reader and/or
OpenFOAM data conversion tools.

How do I run parallel? Same as any other OpenFOAM installation, e.g.: mpirun -np 2 icoFoam-parallel

How do I run parallel on multiple computers? This is not trivial inside the Docker environment. Also you might want to
include optimised communication libraries (MPI) so it probably makes more
sense to perform a native compilation.

How do I compile code? The Docker environment contains a full OpenFOAM development
environment so all Allwmake, wmake, wclean etc. commands work
(it is running the actual environment OpenFOAM was compiled
in!)

What does installOpenFOAM do? It downloads the OpenFOAM image from the Docker Hub and creates a
specialised container. This container

mounts the home directory of the user with read/write access

optionally channels the graphics

sets up the OpenFOAM environment.

The image itself was created from CentOS 7.3. If you wish to install any
additional tool in your docker container, start it as usual via the
startOpenFOAM script, login as root with the password ofuser2017 and use
e.g. yum.

I still have questions... The Docker route to OpenFOAM is new and still being refined. It you have
comments/tips please mail them to: docker (at) opencfd.co.uk.