Difference between revisions of "MPICH2"

From CBLFS
Jump to navigationJump to search
(Added page)
 
 
(8 intermediate revisions by 2 users not shown)
Line 2: Line 2:
 
|-
 
|-
 
!Download Source:
 
!Download Source:
|http://www-unix.mcs.anl.gov/mpi/mpich/downloads/mpich2-{{Mpich2-Version}}.tar.gz
+
|http://www.mcs.anl.gov/research/projects/mpich2/downloads/tarballs/{{Mpich2-Version}}/mpich2-{{Mpich2-Version}}.tar.gz
 
|}
 
|}
  
Line 8: Line 8:
  
 
{{Package-Introduction|MPICH2 is an implementation of the Message-Passing Interface (MPI) version 2.|http://www-unix.mcs.anl.gov/mpi/mpich/}}
 
{{Package-Introduction|MPICH2 is an implementation of the Message-Passing Interface (MPI) version 2.|http://www-unix.mcs.anl.gov/mpi/mpich/}}
 +
 +
== Dependencies ==
 +
 +
=== Required ===
 +
* [[OpenSSH]]
 +
* [[Python]]
  
 
== Configuration Information ==
 
== Configuration Information ==
Line 27: Line 33:
 
  --enable-sharedlibs=gcc --with-pm=mpd:gforker --enable-f90 \
 
  --enable-sharedlibs=gcc --with-pm=mpd:gforker --enable-f90 \
 
  --enable-cxx --with-mpe  --with-device=ch3:sock \
 
  --enable-cxx --with-mpe  --with-device=ch3:sock \
  --with-htmldir=/opt/mpich2/doc/html --mandir=/usr/share/man &&
+
  --with-htmldir=/usr/share/doc/mpich2/html --mandir=/usr/share/man &&
 
  make
 
  make
  
Line 45: Line 51:
 
  --enable-sharedlibs=gcc --with-pm=mpd:gforker --enable-f90 \
 
  --enable-sharedlibs=gcc --with-pm=mpd:gforker --enable-f90 \
 
  --enable-cxx --with-mpe  --with-device=ch3:sock \
 
  --enable-cxx --with-mpe  --with-device=ch3:sock \
  --with-htmldir=/opt/mpich2/doc/html --mandir=/usr/share/man &&
+
  ---with-htmldir=/usr/share/doc/mpich2/html --mandir=/usr/share/man &&
 
  make
 
  make
  
Line 61: Line 67:
 
  --sysconfdir=/etc/mpich2 --enable-sharedlibs=gcc --with-pm=mpd:gforker \  
 
  --sysconfdir=/etc/mpich2 --enable-sharedlibs=gcc --with-pm=mpd:gforker \  
 
  --enable-f90 --enable-cxx --with-mpe  --with-device=ch3:sock \
 
  --enable-f90 --enable-cxx --with-mpe  --with-device=ch3:sock \
  --with-htmldir=/opt/mpich2/doc/html --mandir=/usr/share/man &&
+
  ---with-htmldir=/usr/share/doc/mpich2/html --mandir=/usr/share/man &&
 
  make
 
  make
  
Line 77: Line 83:
 
  --sysconfdir=/etc/mpich2 --enable-sharedlibs=gcc --with-pm=mpd:gforker \  
 
  --sysconfdir=/etc/mpich2 --enable-sharedlibs=gcc --with-pm=mpd:gforker \  
 
  --enable-f90 --enable-cxx --with-mpe  --with-device=ch3:sock \
 
  --enable-f90 --enable-cxx --with-mpe  --with-device=ch3:sock \
  --with-htmldir=/opt/mpich2/doc/html --mandir=/usr/share/man &&
+
  ---with-htmldir=/usr/share/doc/mpich2/html --mandir=/usr/share/man &&
 
  make
 
  make
  
Line 91: Line 97:
  
 
=== Process Manager ===
 
=== Process Manager ===
 +
 
Set the secret word system-wide (required to run process managers as root):
 
Set the secret word system-wide (required to run process managers as root):
 
  echo MPD_SECRETWORD=weibullguyiscool > /etc/mpd.conf
 
  echo MPD_SECRETWORD=weibullguyiscool > /etc/mpd.conf
Line 101: Line 108:
 
=== Bootscript ===
 
=== Bootscript ===
  
Create a boot script to start the MPICH2 process manager on the node.  This is only necessary if you want to bring up the cluster services automatically.
+
Install the mpd init script included in the [[bootscripts]] package.
  
  cat > /etc/rc.d/init.d/mpd << "EOF"
+
  make install-mpich2
#!/bin/sh
 
# Begin $rc_base/init.d/mpd
 
#
 
# Based on sysklogd script from LFS-3.1 and earlier.
 
# Written by Andrew "Weibullguy" Rowland <darowland@ieee.org>
 
#
 
# Date: 2007-10-21 22:22:16
 
 
. /etc/sysconfig/rc
 
. $rc_functions
 
 
# Read in the command arguments
 
case "$1" in
 
    start)
 
        boot_mesg "Starting MPICH2 Process Manager..."
 
        loadproc /usr/sbin/mpd
 
        ;;
 
    stop)
 
        boot_mesg "Stopping MPICH2 Process Manager ..."
 
        killproc mpd
 
        ;;
 
    restart)
 
        $0 stop
 
        $0 start
 
        ;;
 
    status)
 
        statusproc /usr/sbin/mpd
 
        ;;
 
    *)
 
        echo "Usage: $0 {start|stop|restart|status}"
 
        exit 1
 
esac
 
 
exit 0
 
 
# End $rc_base/init.d/mpd
 
EOF
 
  
Link the bootscript into the appropriate run levels.
+
=== Test Suite ===
  
ln -sf  ../init.d/mpd ${EXTDIR}/rc.d/rc0.d/K10mpd
 
ln -sf  ../init.d/mpd ${EXTDIR}/rc.d/rc1.d/K10mpd
 
ln -sf  ../init.d/mpd ${EXTDIR}/rc.d/rc2.d/K10mpd
 
ln -sf  ../init.d/mpd ${EXTDIR}/rc.d/rc3.d/S99mpd
 
ln -sf  ../init.d/mpd ${EXTDIR}/rc.d/rc4.d/S99mpd
 
ln -sf  ../init.d/mpd ${EXTDIR}/rc.d/rc5.d/S99mpd
 
ln -sf  ../init.d/mpd ${EXTDIR}/rc.d/rc6.d/K10mpd
 
 
=== Test Suite ===
 
 
Now that MPICH2 is installed, start the process manager and run the test suite.  The results are output to an XML file that can be viewed in your web browser.  MPICH2 comes with a stylesheet for rendering the XML test results.
 
Now that MPICH2 is installed, start the process manager and run the test suite.  The results are output to an XML file that can be viewed in your web browser.  MPICH2 comes with a stylesheet for rendering the XML test results.
  
Line 161: Line 122:
 
  cp -v test/mpi/summary.xml ../mpich2_test_results
 
  cp -v test/mpi/summary.xml ../mpich2_test_results
 
  firefox ../mpich2_test_results/summary.xml
 
  firefox ../mpich2_test_results/summary.xml
 
Create a boot script to start the MPICH2 process manager on the node.  This is only necessary if you want to bring up the cluster services automatically.
 
  
 
== Contents ==
 
== Contents ==
Line 182: Line 141:
 
{| style="text-align: left;"
 
{| style="text-align: left;"
 
|-valign="top"
 
|-valign="top"
!
+
!mpd
 +
|
 +
|-valign="top"
 +
!mpdboot
 +
|
 +
|-valign="top"
 +
!mpdallext
 
|
 
|
 
|-valign="top"
 
|-valign="top"
!
+
!mpiexec
 
|
 
|
 
|-valign="top"
 
|-valign="top"
!
+
!mpirun
 +
|
 +
|-valign="top"
 +
!mpicc
 +
|
 +
|-valign="top"
 +
!mpicxx
 +
|
 +
|-valign="top"
 +
!mpif90
 
|
 
|
 
|}
 
|}
 +
 +
[[Category:Programming]]
 +
[[Category:Clusters_Grids]]

Latest revision as of 08:54, 19 October 2010

Download Source: http://www.mcs.anl.gov/research/projects/mpich2/downloads/tarballs/1.0.6p1/mpich2-1.0.6p1.tar.gz

Introduction to MPICH2

MPICH2 is an implementation of the Message-Passing Interface (MPI) version 2.

Project Homepage: http://www-unix.mcs.anl.gov/mpi/mpich/

Dependencies

Required

Configuration Information

--with-pm=<PROCESS MANAGER>: Determines which process manager(s) are built where <PROCESS MANAGER> is a colon-separated list of mpd, smpd, or gforker. See the documentation for a discussion of each process manager.
--with-device=<SOCKET>: Selects sockets for interprocess communications where <SOCKET> is one of ch3:sock, ch3:ssm, ch3:shm, or ch3:nemesis. See the documentation for a discussion of each socket type.
Caution.png

Note

Each implementation of MPI (e.g., MPICH2 or OpenMPI) installs certain binaries that have the same name. Subsequent installations will overwrite previous installation. If you plan to use multiple implmentations of MPI, it's recommended that you install each in a separate directory structure such as /opt/mpich2 and /opt/openmpi.

Non-Multilib

Compile the package:

./configure --prefix=/usr --sysconfdir=/etc/mpich2 \
--enable-sharedlibs=gcc --with-pm=mpd:gforker --enable-f90 \
--enable-cxx --with-mpe  --with-device=ch3:sock \
--with-htmldir=/usr/share/doc/mpich2/html --mandir=/usr/share/man &&
make

Install the package:

make install
make install-examples
mv -v /usr/lib/mpich2-ch3.pc /usr/lib/pkgconfig

Multilib

32Bit

Compile the package:

CC="gcc ${BUILD32}"  CXX="g++ ${BUILD32}" ./configure --prefix=/usr --sysconfdir=/etc/mpich2 \
--enable-sharedlibs=gcc --with-pm=mpd:gforker --enable-f90 \
--enable-cxx --with-mpe  --with-device=ch3:sock \
---with-htmldir=/usr/share/doc/mpich2/html --mandir=/usr/share/man &&
make

Install the package:

make install
make install-examples
mv -v /usr/lib/mpich2-ch3.pc /usr/lib/pkgconfig

N32

Compile the package:

CC="gcc ${BUILDN32}"  CXX="g++ ${BUILDN32}" ./configure --prefix=/usr --libdir=/usr/lib32 \
--sysconfdir=/etc/mpich2 --enable-sharedlibs=gcc --with-pm=mpd:gforker \ 
--enable-f90 --enable-cxx --with-mpe  --with-device=ch3:sock \
---with-htmldir=/usr/share/doc/mpich2/html --mandir=/usr/share/man &&
make

Install the package:

make install
make install-examples
mv -v /usr/lib32/mpich2-ch3.pc /usr/lib32/pkgconfig

64Bit

Compile the package:

CC="gcc ${BUILD64}" CXX="g++ ${BUILD64}" ./configure --prefix=/usr --libdir=/usr/lib64 \
--sysconfdir=/etc/mpich2 --enable-sharedlibs=gcc --with-pm=mpd:gforker \ 
--enable-f90 --enable-cxx --with-mpe  --with-device=ch3:sock \
---with-htmldir=/usr/share/doc/mpich2/html --mandir=/usr/share/man &&
make

Install the package:

make install
make install-examples
mv -v /usr/lib64/mpich2-ch3.pc /usr/lib64/pkgconfig

Configuring

The process manager requires a secret word to execute. Don't use your login password!! You can change the secret word below to something you like better.

Process Manager

Set the secret word system-wide (required to run process managers as root):

echo MPD_SECRETWORD=weibullguyiscool > /etc/mpd.conf
chmod 600 /etc/mpd.conf

Set the secret word for an unprivileged user.

echo MPD_SECRETWORD=weibullguyiscool > $HOME/.mpd.conf
chmod 600 $HOME/.mpd.conf

Bootscript

Install the mpd init script included in the bootscripts package.

make install-mpich2

Test Suite

Now that MPICH2 is installed, start the process manager and run the test suite. The results are output to an XML file that can be viewed in your web browser. MPICH2 comes with a stylesheet for rendering the XML test results.

mpd &
make testing
mkdir ../mpich2_test_results
cp -v test/TestResults.xsl ../mpich2_test_results
cp -v test/mpi/summary.xml ../mpich2_test_results
firefox ../mpich2_test_results/summary.xml

Contents

Installed Directories: None
Installed Programs: mpd, mpdboot, mpdallexit, mpiexec, mpirun, mpicc, mpicxx, mpif90
Installed Libraries: libmpich.{a,so}, libmpichcxx.{a,so}, libmpichf90.{a,so}, libmpe.a

Short Descriptions

mpd
mpdboot
mpdallext
mpiexec
mpirun
mpicc
mpicxx
mpif90
Retrieved from "?title=MPICH2&oldid=20326"