[mpich-discuss] MPICH2 on Windows

Jayesh Krishna jayesh at mcs.anl.gov
Tue May 20 09:20:56 CDT 2008


 Hi,
  The job launcher for MPICH2 is mpiexec.exe (not mpirun.exe).
  Try running your MPI app using mpiexec,

mpiexec -n 2 example

  You can also find a sample MPI application, cpi.c, in MPICH2\examples
(The binary version, cpi.exe, is also available at the same location). Try
running the sample application using mpiexec,

mpiexec -n 2 cpi.exe
   

(PS: You don't have to explicitly specify the hosts if all the MPI
processes are to be launched in the same machine. Also use the
"-machinefile" option when running your MPI app across hosts. You can find
more information on the various options provided by mpiexec in the windows
developer's guide available at
http://www.mcs.anl.gov/research/projects/mpich2/documentation/index.php?s=
docs)

Regards,
Jayesh

-----Original Message-----
From: owner-mpich-discuss at mcs.anl.gov
[mailto:owner-mpich-discuss at mcs.anl.gov] On Behalf Of Jacek Strzelczyk
Sent: Tuesday, May 20, 2008 7:21 AM
To: mpich-discuss at mcs.anl.gov
Subject: [mpich-discuss] MPICH2 on Windows

Hello everyone,
I'm trying to get MPICH2 working on Windows 2000. I've installed it
without any problems and than I try to run simplest MPI Job with few
processes.

The job code is:
#include <stdio.h>
#include "mpi.h"
int main( int argc, char *argv[] )
{
     int rank;
     int size;

     MPI_Init( 0, 0 );
     MPI_Comm_rank(MPI_COMM_WORLD, &rank);
     MPI_Comm_size(MPI_COMM_WORLD, &size);
     printf( "Hello world from process %d of %d\n", rank, size );
     MPI_Finalize();
     return 0;
}

I run it by:
mpirun.exe -hosts 2 k43 k43 example
where k43 is the name of my computer

What I get in return is:
Hello world from process 0 of 1
Hello world from process 0 of 1

Why those two processes are not in one group? They can't communicate!
When I run the same job using MPICH (not MPICH2) I get proper answer:
Hello world from process 1 of 2
Hello world from process 0 of 2

What's wrong in here?
Thanks in advance,
Jacek


--
Jacek Strzelczyk
http://szczelba.lfa.pl
szczelba at op.pl, jacek.strzelczyk at it.wkrakowie.org
JID: szczelba at chrome.pl


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/mpich-discuss/attachments/20080520/ae10baf4/attachment.htm>


More information about the mpich-discuss mailing list