|
Packit Service |
c5cf8c |
.TH mpiexec 1 "11/12/2019" " " "MPI"
|
|
Packit Service |
c5cf8c |
.SH NAME
|
|
Packit Service |
c5cf8c |
mpiexec \- Run an MPI program
|
|
Packit Service |
c5cf8c |
.SH SYNOPSIS
|
|
Packit Service |
c5cf8c |
.nf
|
|
Packit Service |
c5cf8c |
.fi
|
|
Packit Service |
c5cf8c |
.nf
|
|
Packit Service |
c5cf8c |
mpiexec args executable pgmargs [ : args executable pgmargs ... ]
|
|
Packit Service |
c5cf8c |
.fi
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
where
|
|
Packit Service |
c5cf8c |
.I args
|
|
Packit Service |
c5cf8c |
are command line arguments for
|
|
Packit Service |
c5cf8c |
.I mpiexec
|
|
Packit Service |
c5cf8c |
(see below),
|
|
Packit Service |
c5cf8c |
.I executable
|
|
Packit Service |
c5cf8c |
is the name of an executable MPI program, and
|
|
Packit Service |
c5cf8c |
.I pgmargs
|
|
Packit Service |
c5cf8c |
are command line arguments for the executable. Multiple executables
|
|
Packit Service |
c5cf8c |
can be specified by using the colon notation (for MPMD - Multiple Program
|
|
Packit Service |
c5cf8c |
Multiple Data applications). For example, the following command will run
|
|
Packit Service |
c5cf8c |
the MPI program
|
|
Packit Service |
c5cf8c |
.I a.out
|
|
Packit Service |
c5cf8c |
on 4 processes:
|
|
Packit Service |
c5cf8c |
.nf
|
|
Packit Service |
c5cf8c |
mpiexec -n 4 a.out
|
|
Packit Service |
c5cf8c |
.fi
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
The MPI standard specifies the following arguments and their meanings:
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -n <np>
|
|
Packit Service |
c5cf8c |
- Specify the number of processes to use
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -host <hostname>
|
|
Packit Service |
c5cf8c |
- Name of host on which to run processes
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -arch <architecture name>
|
|
Packit Service |
c5cf8c |
- Pick hosts with this architecture type
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -wdir <working directory>
|
|
Packit Service |
c5cf8c |
- cd to this one
|
|
Packit Service |
c5cf8c |
.B before
|
|
Packit Service |
c5cf8c |
running executable
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -path <pathlist>
|
|
Packit Service |
c5cf8c |
- use this to find the executable
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -soft <triplets>
|
|
Packit Service |
c5cf8c |
- comma separated triplets that specify requested numbers
|
|
Packit Service |
c5cf8c |
of processes (see the MPI-2 specification for more details)
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -file <name>
|
|
Packit Service |
c5cf8c |
- implementation-defined specification file
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -configfile <name>
|
|
Packit Service |
c5cf8c |
- file containing specifications of host/program,
|
|
Packit Service |
c5cf8c |
one per line, with # as a comment indicator, e.g., the usual
|
|
Packit Service |
c5cf8c |
mpiexec input, but with ":" replaced with a newline. That is,
|
|
Packit Service |
c5cf8c |
the configfile contains lines with -soft, -n etc.
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
Additional arguments that are specific to the MPICH implementation
|
|
Packit Service |
c5cf8c |
are discussed below.
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
Note that not all of these parameters are meaningful for all
|
|
Packit Service |
c5cf8c |
systems. For example, the
|
|
Packit Service |
c5cf8c |
.I gforker
|
|
Packit Service |
c5cf8c |
version of
|
|
Packit Service |
c5cf8c |
.I mpiexec
|
|
Packit Service |
c5cf8c |
creates all
|
|
Packit Service |
c5cf8c |
processes on the same system on which it is running; in that case, the
|
|
Packit Service |
c5cf8c |
.I \\-arch
|
|
Packit Service |
c5cf8c |
and
|
|
Packit Service |
c5cf8c |
.I \\-host
|
|
Packit Service |
c5cf8c |
options are ignored.
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
The colon character (
|
|
Packit Service |
c5cf8c |
.I :
|
|
Packit Service |
c5cf8c |
) may be used to separate different executables
|
|
Packit Service |
c5cf8c |
for MPMD (multiple program multiple data) programming. For example,
|
|
Packit Service |
c5cf8c |
to run the program
|
|
Packit Service |
c5cf8c |
.I ocean
|
|
Packit Service |
c5cf8c |
on 4 processes and
|
|
Packit Service |
c5cf8c |
.I air
|
|
Packit Service |
c5cf8c |
on 8 processes, use:
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.nf
|
|
Packit Service |
c5cf8c |
mpiexec -n 4 ocean : -n 8 air
|
|
Packit Service |
c5cf8c |
.fi
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.SH MPICH-SPECIFIC ARGUMENTS
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
Many of the implementations of process managers in MPICH support the
|
|
Packit Service |
c5cf8c |
following arguments to
|
|
Packit Service |
c5cf8c |
.I mpiexec
|
|
Packit Service |
c5cf8c |
:
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -np <num>
|
|
Packit Service |
c5cf8c |
- A synonym for the standard
|
|
Packit Service |
c5cf8c |
.I \\-n
|
|
Packit Service |
c5cf8c |
argument
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -env <name> <value>
|
|
Packit Service |
c5cf8c |
- Set the environment variable
|
|
Packit Service |
c5cf8c |
.I <name>
|
|
Packit Service |
c5cf8c |
to
|
|
Packit Service |
c5cf8c |
.I <value>
|
|
Packit Service |
c5cf8c |
for
|
|
Packit Service |
c5cf8c |
the processes being run by
|
|
Packit Service |
c5cf8c |
.I mpiexec
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -envnone
|
|
Packit Service |
c5cf8c |
- Pass no environment variables (other than ones specified with
|
|
Packit Service |
c5cf8c |
other
|
|
Packit Service |
c5cf8c |
.I \\-env
|
|
Packit Service |
c5cf8c |
or
|
|
Packit Service |
c5cf8c |
.I \\-genv
|
|
Packit Service |
c5cf8c |
arguments) to the processes being run by
|
|
Packit Service |
c5cf8c |
.I mpiexec
|
|
Packit Service |
c5cf8c |
\&.
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
By default, all environment
|
|
Packit Service |
c5cf8c |
variables are provided to each MPI process (rationale: principle of
|
|
Packit Service |
c5cf8c |
least surprise for the user)
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -envlist <list>
|
|
Packit Service |
c5cf8c |
- Pass the listed environment variables (names separated
|
|
Packit Service |
c5cf8c |
by commas), with their current values, to the processes being run by
|
|
Packit Service |
c5cf8c |
.I mpiexec
|
|
Packit Service |
c5cf8c |
\&.
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -genv <name> <value>
|
|
Packit Service |
c5cf8c |
- The
|
|
Packit Service |
c5cf8c |
.I \\-genv
|
|
Packit Service |
c5cf8c |
options have the same meaning as their
|
|
Packit Service |
c5cf8c |
corresponding
|
|
Packit Service |
c5cf8c |
.I \\-env
|
|
Packit Service |
c5cf8c |
version, except they apply to all executables, not just
|
|
Packit Service |
c5cf8c |
the current executable (in the case that the colon syntax is used to specify
|
|
Packit Service |
c5cf8c |
multiple execuables).
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -genvnone
|
|
Packit Service |
c5cf8c |
- Like
|
|
Packit Service |
c5cf8c |
.I \\-envnone
|
|
Packit Service |
c5cf8c |
, but for all executables
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -genvlist <list>
|
|
Packit Service |
c5cf8c |
- Like
|
|
Packit Service |
c5cf8c |
.I \\-envlist
|
|
Packit Service |
c5cf8c |
, but for all executables
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -usize <n>
|
|
Packit Service |
c5cf8c |
- Specify the value returned for the value of the attribute
|
|
Packit Service |
c5cf8c |
.I MPI_UNIVERSE_SIZE
|
|
Packit Service |
c5cf8c |
\&.
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -l
|
|
Packit Service |
c5cf8c |
- Label standard out and standard error (
|
|
Packit Service |
c5cf8c |
.I stdout
|
|
Packit Service |
c5cf8c |
and
|
|
Packit Service |
c5cf8c |
.I stderr
|
|
Packit Service |
c5cf8c |
) with
|
|
Packit Service |
c5cf8c |
the rank of the process
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -maxtime <n>
|
|
Packit Service |
c5cf8c |
- Set a timelimit of
|
|
Packit Service |
c5cf8c |
.I <n>
|
|
Packit Service |
c5cf8c |
seconds.
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B -exitinfo
|
|
Packit Service |
c5cf8c |
- Provide more information on the reason each process exited if
|
|
Packit Service |
c5cf8c |
there is an abnormal exit
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.SH ENVIRONMENT VARIABLES FOR MPIEXEC
|
|
Packit Service |
c5cf8c |
The following environment variables are understood by some versions of
|
|
Packit Service |
c5cf8c |
.I mpiexec
|
|
Packit Service |
c5cf8c |
\&.
|
|
Packit Service |
c5cf8c |
The command line arguments have priority over these; that is,
|
|
Packit Service |
c5cf8c |
if both the environment variable and command line argument are used, the
|
|
Packit Service |
c5cf8c |
value specified by the command line argument is used.
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B MPIEXEC_TIMEOUT
|
|
Packit Service |
c5cf8c |
- Maximum running time in seconds.
|
|
Packit Service |
c5cf8c |
.I mpiexec
|
|
Packit Service |
c5cf8c |
will
|
|
Packit Service |
c5cf8c |
terminate MPI programs that take longer than the value specified by
|
|
Packit Service |
c5cf8c |
.I MPIEXEC_TIMEOUT
|
|
Packit Service |
c5cf8c |
\&.
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B MPIEXEC_UNIVERSE_SIZE
|
|
Packit Service |
c5cf8c |
- Set the universe size
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B MPIEXEC_PORT_RANGE
|
|
Packit Service |
c5cf8c |
- Set the range of ports that
|
|
Packit Service |
c5cf8c |
.I mpiexec
|
|
Packit Service |
c5cf8c |
will use
|
|
Packit Service |
c5cf8c |
in communicating with the processes that it starts. The format of
|
|
Packit Service |
c5cf8c |
this is
|
|
Packit Service |
c5cf8c |
.I <low>:<high>
|
|
Packit Service |
c5cf8c |
\&.
|
|
Packit Service |
c5cf8c |
For example, to specify any port between
|
|
Packit Service |
c5cf8c |
10000 and 10100, use
|
|
Packit Service |
c5cf8c |
.I 10000:10100
|
|
Packit Service |
c5cf8c |
\&.
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B MPICH_PORT_RANGE
|
|
Packit Service |
c5cf8c |
- Has the same meaning as
|
|
Packit Service |
c5cf8c |
.I MPIEXEC_PORT_RANGE
|
|
Packit Service |
c5cf8c |
and
|
|
Packit Service |
c5cf8c |
is used if
|
|
Packit Service |
c5cf8c |
.I MPIEXEC_PORT_RANGE
|
|
Packit Service |
c5cf8c |
is not set.
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B MPIEXEC_PREFIX_DEFAULT
|
|
Packit Service |
c5cf8c |
- If this environment variable is set, output
|
|
Packit Service |
c5cf8c |
to standard output is prefixed by the rank in
|
|
Packit Service |
c5cf8c |
.I MPI_COMM_WORLD
|
|
Packit Service |
c5cf8c |
of the
|
|
Packit Service |
c5cf8c |
process and output to standard error is prefixed by the rank and the
|
|
Packit Service |
c5cf8c |
text
|
|
Packit Service |
c5cf8c |
.I (err)
|
|
Packit Service |
c5cf8c |
; both are followed by an angle bracket (
|
|
Packit Service |
c5cf8c |
.I >
|
|
Packit Service |
c5cf8c |
). If
|
|
Packit Service |
c5cf8c |
this variable is not set, there is no prefix.
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B MPIEXEC_PREFIX_STDOUT
|
|
Packit Service |
c5cf8c |
- Set the prefix used for lines sent to standard
|
|
Packit Service |
c5cf8c |
output. A
|
|
Packit Service |
c5cf8c |
.I %d
|
|
Packit Service |
c5cf8c |
is replaced with the rank in
|
|
Packit Service |
c5cf8c |
.I MPI_COMM_WORLD
|
|
Packit Service |
c5cf8c |
; a
|
|
Packit Service |
c5cf8c |
.I %w
|
|
Packit Service |
c5cf8c |
is
|
|
Packit Service |
c5cf8c |
replaced with an indication of which
|
|
Packit Service |
c5cf8c |
.I MPI_COMM_WORLD
|
|
Packit Service |
c5cf8c |
in MPI jobs that
|
|
Packit Service |
c5cf8c |
involve multiple
|
|
Packit Service |
c5cf8c |
.I MPI_COMM_WORLD
|
|
Packit Service |
c5cf8c |
s (e.g., ones that use
|
|
Packit Service |
c5cf8c |
.I MPI_Comm_spawn
|
|
Packit Service |
c5cf8c |
or
|
|
Packit Service |
c5cf8c |
.I MPI_Comm_connect
|
|
Packit Service |
c5cf8c |
).
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
.PD 0
|
|
Packit Service |
c5cf8c |
.TP
|
|
Packit Service |
c5cf8c |
.B MPIEXEC_PREFIX_STDERR
|
|
Packit Service |
c5cf8c |
- Like
|
|
Packit Service |
c5cf8c |
.I MPIEXEC_PREFIX_STDOUT
|
|
Packit Service |
c5cf8c |
, but for standard error.
|
|
Packit Service |
c5cf8c |
.PD 1
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
.SH RETURN STATUS
|
|
Packit Service |
c5cf8c |
.I mpiexec
|
|
Packit Service |
c5cf8c |
returns the maximum of the exit status values of all of the
|
|
Packit Service |
c5cf8c |
processes created by
|
|
Packit Service |
c5cf8c |
.I mpiexec
|
|
Packit Service |
c5cf8c |
\&.
|
|
Packit Service |
c5cf8c |
|
|
Packit Service |
c5cf8c |
|