This recipe shows how to run the mpiBench benchmark on Linux using MPICH over Azure VM instances in an Azure Batch compute pool. Execution of this distributed workload requires the use of multi-instance tasks.
Execution under both Docker and Singularity are shown in this recipe.
Please see refer to the set of sample configuration files for
this recipe. The directory docker
will contain the Docker-based execution
while the singularity
directory will contain the Singularity-based
execution configuration.
The pool configuration should enable the following properties:
inter_node_communication_enabled
must be set totrue
max_tasks_per_node
must be set to 1 or omitted
The pool configuration should enable the following properties:
inter_node_communication_enabled
must be set totrue
max_tasks_per_node
must be set to 1 or omittedadditional_node_prep
should contains the commands necessary for installing MPICH on the node. For example:- apt-get update - apt-get install -y --no-install-recommends mpich
container_runtimes
should be set to installsingularity
The global configuration should set the following properties:
docker_images
array must have a reference to a valid mpiBench image that can be run with MPICH. This can bevincentlabo/mpibench:mpich
which is published on Docker Hub.
The global configuration should set the following properties:
singularity_images
array must have a reference to a valid mpiBench image that can be run with MPICH. This can belibrary://vincent.labonte/mpi/mpibench:mpich
which is published on Sylabs Cloud.
The jobs configuration should set the following properties within the tasks
array which should have a task definition containing:
docker_image
should be the name of the Docker image for this container invocation. For this example, this should bevincentlabo/mpibench:mpich
.command
should contain the command to pass to thempirun
invocation. For this example, we will run mpiBench with an ending message size of 1kB. The applicationcommand
to run would be:/mpiBench/mpiBench -e 1K
multi_instance
property must be definednum_instances
should be set topool_specification_vm_count_dedicated
,pool_specification_vm_count_low_priority
,pool_current_dedicated
, orpool_current_low_priority
coordination_command
should be unset ornull
. For pools withnative
container support, this command should be supplied if a non-standardsshd
is required.resource_files
should be unset or the array can be emptympi
property must be definedruntime
should be set tompich
processes_per_node
should be set tonproc
The jobs configuration should set the following properties within the tasks
array which should have a task definition containing:
singularity_image
should be the name of the Singularity image for this container invocation. For this example, this should belibrary://vincent.labonte/mpi/mpibench:mpich
.command
should contain the command to pass to thempirun
invocation. For this example, we will run mpiBench with an ending message size of 1kB. The applicationcommand
to run would be:/mpiBench/mpiBench -e 1K
multi_instance
property must be definednum_instances
should be set topool_specification_vm_count_dedicated
,pool_specification_vm_count_low_priority
,pool_current_dedicated
, orpool_current_low_priority
coordination_command
should be unset ornull
.resource_files
should be unset or the array can be emptympi
property must be definedruntime
should be set tompich
processes_per_node
should be set tonproc
The Dockerfile
for the Docker image can be found here.
The Singularity Definition file for the Singularity image can be found
here.