cc_staff
153
edits
m (Update singularity docs to indicate mpi needs to be configured with pmi2 and slurm or pmix matching the cluster's configuration.) |
(Clarify recent edits a bit) |
||
Line 414: | Line 414: | ||
* Ensuring your MPI program is compiled using the OpenMPI installed inside your Singularity container. | * Ensuring your MPI program is compiled using the OpenMPI installed inside your Singularity container. | ||
** Ideally the version of OpenMPI inside the container is version 3 or 4. Version 2 may or may not work. Version 1 will not work. | ** Ideally the version of OpenMPI inside the container is version 3 or 4. Version 2 may or may not work. Version 1 will not work. | ||
* Ensure the MPI installation in the container | * Ensure the MPI installation in the container can use the same process-management interface library as the MPI version on the cluster, e.g. PMI-2 or PMIx. | ||
* Ensuring your SLURM job script uses <code>srun</code> to run the MPI program, and have srun use | * Ensuring your SLURM job script uses <code>srun</code> to run the MPI program, and have srun use a pmi library that is supported by the MPI implementation in the container. Do not use <code>mpirun</code> or <code>mpiexec</code>, e.g., | ||
<source lang="bash"> | <source lang="bash"> | ||
srun --mpi=pmi2 singularity exec /path/to/your/singularity/image.sif /path/to/your-program | srun --mpi=pmi2 singularity exec /path/to/your/singularity/image.sif /path/to/your-program | ||
</source> | </source> | ||
if the MPI implementation in the container only supports PMI-2 (use <code>--mpi=pmix</code> for PMIx). | |||
* Ensure there are no module load commands in your job script. | * Ensure there are no module load commands in your job script. | ||
* Install the <code>slurm-client</code> package from your distribution within your container to enable interaction(s) with the Slurm scheduler. | * Install the <code>slurm-client</code> package from your distribution within your container to enable interaction(s) with the Slurm scheduler. |