when executing OpenFoam inside the new Apptainer container of2406-py2.5.0-cpu.sif using WSL, an attempting parallel run leads to the error as already mentioned in #33 :
--> FOAM FATAL ERROR: (openfoam-2406)
attempt to run parallel on 1 processor
From static bool Foam::UPstream::init(int&, char**&, bool)
in file UPstream.C at line 286.
FOAM aborting
Versions
on Linux native system: Ubuntu 20.3, Apptainer version 1.2.2 OpenMPI version 4.0.3 (works)
WSL on Windows 10: Ubuntu 24.04 LTS, Apptainer version 1.3.4 OpenMPI version 4.0.3 (issue)
Inside the Container: Apptainer version 4.1.6, OpenFOAM version2406
On the Linux native system everything works as expected without any issues, despite the different version of OpenMPI. On WSL, however, the mentioned error occurs. I assume that has something to do with the newer Ubuntu version on WSL.
Fix
This issue can be fixed by installing OpenMPI v4.1.6 by executing sudo apt install openmpi-bin, which (at the moment) installes the correct MPI version. Otherwise, the correct version can be installed following the instructions provided on the OpenMPI website.
After installation verify that the correct version is installed by executing mpirun --version, which should yield:
mpirun (Open MPI) 4.1.6
Report bugs to http://www.open-mpi.org/community/help/
Just for the record, the Basilisk container basilisk.sif using OpenMPI v1.10.2 works without any issues on both systems. We will probably encounter this issue in exercise 9 as well since drlfoam still uses the old container and OpenMPI version. I will open another issue once I checked that.
Hi @AndreWeiner,
Issue
when executing OpenFoam inside the new Apptainer container
of2406-py2.5.0-cpu.sif
using WSL, an attempting parallel run leads to the error as already mentioned in #33 :Versions
1.2.2
OpenMPI version4.0.3
(works)24.04 LTS
, Apptainer version1.3.4
OpenMPI version4.0.3
(issue)4.1.6
, OpenFOAM version2406
On the Linux native system everything works as expected without any issues, despite the different version of
OpenMPI
. On WSL, however, the mentioned error occurs. I assume that has something to do with the newer Ubuntu version on WSL.Fix
This issue can be fixed by installing
OpenMPI v4.1.6
by executingsudo apt install openmpi-bin
, which (at the moment) installes the correct MPI version. Otherwise, the correct version can be installed following the instructions provided on the OpenMPI website.After installation verify that the correct version is installed by executing
mpirun --version
, which should yield:Just for the record, the Basilisk container
basilisk.sif
usingOpenMPI v1.10.2
works without any issues on both systems. We will probably encounter this issue in exercise 9 as well since drlfoam still uses the old container andOpenMPI
version. I will open another issue once I checked that.Regards, Janis