mpiexec(1)

mpiexec1

Run an mpi program

Usage

mpiexec args executable pgmargs [: args executable pgmargs ...]

mpiexec -n 4 a.out

The MPI standard specifies the following arguments and their meanings:

Mpich-specific arguments

Many of the implementations of process managers in MPICH support the following arguments to mpiexec :

-np <num>

- A synonym for the standard \-n argument

-env <name> <value>

- Set the environment variable <name> to <value> for the processes being run by mpiexec

-envnone

- Pass no environment variables (other than ones specified with other \-env or \-genv arguments) to the processes being run by mpiexec .

By default, all environment variables are provided to each MPI process (rationale: principle of least surprise for the user)

-envlist <list>

- Pass the listed environment variables (names separated by commas), with their current values, to the processes being run by mpiexec .

-genv <name> <value>

- The \-genv options have the same meaning as their corresponding \-env version, except they apply to all executables, not just the current executable (in the case that the colon syntax is used to specify multiple executables).

-genvnone

- Like \-envnone , but for all executables

-genvlist <list>

- Like \-envlist , but for all executables

-usize <n>

- Specify the value returned for the value of the attribute MPI_UNIVERSE_SIZE .

-l

- Label standard out and standard error ( stdout and stderr ) with the rank of the process

-maxtime <n>

- Set a timelimit of <n> seconds.

-exitinfo

- Provide more information on the reason each process exited if there is an abnormal exit

Environment variables for mpiexec

The following environment variables are understood by some versions of mpiexec . The command line arguments have priority over these; that is, if both the environment variable and command line argument are used, the value specified by the command line argument is used.

MPIEXEC_TIMEOUT

- Maximum running time in seconds. mpiexec will terminate MPI programs that take longer than the value specified by MPIEXEC_TIMEOUT .

MPIEXEC_UNIVERSE_SIZE

- Set the universe size

MPIEXEC_PORT_RANGE

- Set the range of ports that mpiexec will use in communicating with the processes that it starts. The format of this is <low>:<high> . For example, to specify any port between 10000 and 10100, use 10000:10100 .

MPICH_PORT_RANGE

- Has the same meaning as MPIEXEC_PORT_RANGE and is used if MPIEXEC_PORT_RANGE is not set.

MPIEXEC_PREFIX_DEFAULT

- If this environment variable is set, output to standard output is prefixed by the rank in MPI_COMM_WORLD of the process and output to standard error is prefixed by the rank and the text (err) ; both are followed by an angle bracket ( > ). If this variable is not set, there is no prefix.

MPIEXEC_PREFIX_STDOUT

- Set the prefix used for lines sent to standard output. A %d is replaced with the rank in MPI_COMM_WORLD ; a %w is replaced with an indication of which MPI_COMM_WORLD in MPI jobs that involve multiple MPI_COMM_WORLD s (e.g., ones that use MPI_Comm_spawn or MPI_Comm_connect ).

MPIEXEC_PREFIX_STDERR

- Like MPIEXEC_PREFIX_STDOUT , but for standard error.

Return status

mpiexec returns the maximum of the exit status values of all of the processes created by mpiexec .

Releases

2 releases since Debian 3.1 (Sarge); the text changed 1 time.

  1. 3.1
  2. 12

-arch until Debian 3.1 (Sarge); -boot until Debian 3.1 (Sarge); -boot-args until Debian 3.1 (Sarge); -d until Debian 3.1 (Sarge); -file until Debian 3.1 (Sarge); -host until Debian 3.1 (Sarge); -machinefile until Debian 3.1 (Sarge); -n until Debian 3.1 (Sarge); -path until Debian 3.1 (Sarge); -prefix until Debian 3.1 (Sarge); -soft until Debian 3.1 (Sarge); -tv until Debian 3.1 (Sarge); -v until Debian 3.1 (Sarge); -wdir until Debian 3.1 (Sarge).

From mpich-doc 4.0.2-3 in Debian 12 (Bookworm). Parsed by carta from the page's man source.