Hi Shervin,
Beyond what Alan has said, yes the MPI needs to be "the same" on the
host as well as in the container. You're starting MPI on the host, but
your MPI command is running singularity which is then using that host
initiated MPI session to do the MPI work that happens in the program
started inside the container. For OpenMPI if the versions are
different, but they're ABI compatible then it _should_ still work...
still the possibility of something popping up where the two versions
don't talk to each other right exists.
> what is the benefits of putting the software in a container in the
first place
Say you have a program that requires an old library version that no
longer exists in a recent distribution. You could build a container
based on the old distribution, and still run it on new systems since
to the program being executed it is running in the older distribution.
For serial/threaded programs, you shouldn't see an issue no matter
where you run it. You get more restrictions once you start needing to
talk between multiple hosts. If you're running an MPI job on a single
node, you could try starting MPI from within the container. So, in
your example since you're running with '-n 4' (four processes), you
could try running:
singularity exec of4.img mpiexec -n 4 simplefoam -parallel
As long as your MPI install in the container will work on the host,
that should work and be portable. You can test by running hostname, or
similar, to see if it would work. But, once you go multinode that
_will not work_ as you will be *outside* the container when mpiexec
goes to start the binary on another host.
So, in that case we need to start singularity through MPI itself as
you have done, and that gives us the restriction that the host MPI and
container MPI need to be compatible. Us saying "the same version" is
an easy way to cut off any possible issues and is usually pretty easy
to accomplish.
Does that make sense?
-J
>> > email to
singularity...@lbl.gov.
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "singularity" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to
singularity...@lbl.gov.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "singularity" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to
singularity...@lbl.gov.