Running examples


Up: Quick Start Next: Sample MPI programs Previous: Configuring, Making, and Installing

    1. Start the MPD daemons. This is described in detail in Section Starting and Managing the MPD Daemons ; however, to start running on your local machine, you can do the following:
      1. Create an .mpd.conf file in your home directory. This contains a password used only for the mpd system. Use the following steps
          cd 
          touch .mpd.conf 
          chmod og-rw .mpd.conf 
          echo "password=mympdpassword" >> .mpd.conf 
      
      where mympdpassword is a password that you have chosen that is different from any other passwords that you use (e.g., do not use your login password!). The other steps make sure that the file is created in your home directory and that it has the correct permissions.


      2. Start an mpd demon:

          mpd -b & 
      
      This starts an mpd demon in the background (no standard output or error).
    At this point, you are ready to run programs, even ones with multiple processes, on the current machine.


    2. (Optional) Build and run a simple test program:

        % cd examples/basic 
        % make cpi 
        % ../../bin/mpirun -np 4 cpi 
    
    At this point you have run an MPI program on your system. If you have trouble, see Section In Case of Trouble .


    3. (Optional) Put the distribution through its complete acceptance test (See Section Thorough Testing for how to do this).


    4. (Optional) If you wish to install mpich in a public place so that others may use it, use

        % make install 
    
    to install mpich into the directory specified by the --prefix option to configure. Installation will consist of an include, lib, bin, sbin, www, and man directories and a small examples directory. Should you wish to remove the installation, you can run the script sbin/mpiuninstall. This step is required in the case of the ch_p4mpd device.


    5. (Optional) At this point you can announce to your users how to compile and run MPI programs, using the installation you have just built in /usr/local/mpich-1.2.5/ (or wherever you have installed it). See Section Programming Tools for commands they can use. They can also copy the Makefile in /usr/local/mpich-1.2.5/examples and adapt it for their own use.



Up: Quick Start Next: Sample MPI programs Previous: Configuring, Making, and Installing