Search⌘ K

Slurm distrbuted MPI and GPU jobs

Explore how to manage distributed MPI processes and GPU jobs using Slurm job scripts. Learn to allocate CPU cores, nodes, and GPUs for multi-process workloads on HPC systems with practical examples.

We'll cover the following...

A MPI job can considered as a cross-node and multi-process job. Sample Slurm MPI job script would look like below:

Shell
#!/bin/bash
#SBATCH --job-name=MyJob
#SBATCH --account=username
#SBATCH --ntasks=32
#SBATCH --ntasks-per-node=16
#SBATCH --cpus-per-tasks=1
module load openmpi
mpiexec <program>

The script ...