|
MVAPICH2 1.8.1 Quick Start Guide
MVAPICH Team Last revised: January 1, 2013 |
This Quick Start contains the necessary information for MVAPICH2 users to download, install, and use MVAPICH2 1.8.1. Please refer to our User Guide for the comprehensive list of all features and instructions about how to use them.
MVAPICH2 (pronounced as “em-vah-pich 2”) is an open-source MPI software to exploit the novel features and mechanisms of high-performance networking technologies (InfiniBand, 10GigE/iWARP and 10/40GigE RDMA over Converged Enhanced Ethernet (RoCE)) and deliver best performance and scalability to MPI applications. This software is developed in the Network-Based Computing Laboratory (NBCL), headed by Prof. Dhabaleswar K. (DK) Panda since 2001.
More details on MVAPICH2 software, users list, mailing lists, sample performance numbers on a wide range of platforms and interconnects, a set of OSU benchmarks and related publications can be obtained from our website.
The MVAPICH2 1.8.1 source code package includes MPICH2 1.4.1p1. All the required files are present in a single tarball.
Download the most recent distribution tarball from http://mvapich.cse.ohio-state.edu/download/mvapich2/mvapich2-1.8.1.tgz
$ wget http://mvapich.cse.ohio-state.edu/download/mvapich2/mvapich2-1.8.1.tgz
$ gzip -dc mvapich2-1.8.1.tgz | tar -x $ cd mvapich2-1.8.1 |
If you’re using a Mellanox InfiniBand, RoCE, or iWARP network adapter you can use the default configuration…
$ ./configure
|
If you’re using a QLogic InfiniBand adapter you should use…
$ ./configure --with-device=ch3:psm
|
MVAPICH2 supports many other configure and run time options which may be useful for advanced users. Please refer to our User Guide for more complete details.
$ make
$ make install |
In this section we will show how to build and run a hello world program which uses mpi.
$ mpicc -o mpihello mpihello.c <1>
$ mpirun_rsh -hostfile hosts -n 2 ./mpihello <2> |
mpirun_rsh <options> <env variables> <command>
|
Hostfile Format The mpirun_rsh hostfile format allows for users to specify hostnames, one per line, optionally with a multiplier, and HCA specification. The multiplier allows you to save typing by allowing you to specify blocked distribution of MPI ranks using one line per hostname. The HCA specification allows you to force an MPI rank to use a particular HCA. The optional components are delimited by a ‘:’. Comments and empty lines are also allowed. Comments start with ‘#’ and continue to the next newline.
The following demonstrates the distribution of MPI ranks when using different hostfiles:
node1
node2 |
node1
node1 node2 node2 |
node1:2
node2:2 |
$ mpirun_rsh -hostfile hosts1 -n 4 ./mpihello
rank 0 on node1 says hello! rank 1 on node2 says hello! rank 2 on node1 says hello! rank 3 on node2 says hello! $ mpirun_rsh -hostfile hosts2 -n 4 ./mpihello rank 0 on node1 says hello! rank 1 on node1 says hello! rank 2 on node2 says hello! rank 3 on node2 says hello! $ mpirun_rsh -hostfile hosts3 -n 4 ./mpihello rank 0 on node1 says hello! rank 1 on node1 says hello! rank 2 on node2 says hello! rank 3 on node2 says hello! |
env variables Environment variables are specified using the ‘NAME=VALUE’ syntax directly before the command name is specified. Pass an environment variable named FOO with the value BAR
$ mpirun_rsh -hostfile hosts -n 2 FOO=BAR ./mpihello
|
MVAPICH2 supports other launchers and resource managers such as Hydra, SLURM, and PBS. Please look at our User Guide for more complete details.
Please see the following for more information.