1. Install Image and set hostfile
$ docker pull nbclosu/mvapich:3.0 $ docker run -it --privileged nbclosu/mvapich:3.0 /bin/bash
$ echo <container-id> > /hostfile
Hostfile is for specifying the list of nodes/containers where the job is running. Within the docker container, your hostname is the <container-id>. In this test, your hostfile needs to contain only one line of <container-id> information.
2. Running OMB
Now you can run OMB with specific benchmarks (osu_latency, osu_bw, osu_bibw …). You can also change the number of processors (-np) for benchmarks.
$ docker exec <container-id> /mvapich-3.0-install/bin/mpirun_rsh -np 2 -hostfile /hostfile /mvapich-3.0-install/libexec/osu-micro-benchmarks/mpi/pt2pt/osu_latency
3. Singularity(Apptainer) Support
Many HPC systems only support singularity for containerized applications. You can convert this MVAPICH docker container to SIF(Singularity Image File) with the following commands. In this case, your hostfile contains the hostname, not <container-id>. You can check your hostname with the hostname command.
$ docker save nbclosu/mvapich:3.0 -o mvapich-3.0.tar $ apptainer build mvapich-3.0.sif docker-archive://mvapich-3.0.tar