[mpich-discuss] Help

Anthony Chan chan at mcs.anl.gov
Mon Apr 25 11:34:34 CDT 2011


"test" is common unix command, so use some other executable name
besides "test".  Instead, try the follow commands:

mpicc -o foo test.c
mpiexec -n 2 ./foo

----- Original Message -----
> use mpirun -np number of processes ./exefile instead Marcia
> 
> Date: Mon, 25 Apr 2011 08:26:49 -0300
> From: marcianasare at gmail.com
> To: mpich-discuss at mcs.anl.gov
> Subject: [mpich-discuss] Help
> 
> Hi, I'm newbie in MPI applications and I have a lot of questions. But
> my first problem is with the execution.
> I try execute the code using mpiexec, but never find the library
> mpi.h. I start with a simple code:
> 
> 
> 
> #include <stdio.h>
> #include <mpi.h>
> 
> int main(int argc, char **argv){
> 
> int t;
> t = MPI_Init(&argc,&argv);
> if(t == MPI_SUCCESS){
> printf("test ok");
> 
> 
> }
> MPI_Finalize();
> return 0;
> }
> 
> 
> 
> 
> So, I compiled with mpicc test.c -o test. The result was the
> executable, but it isn't work. The mensage no such file or directory.
> I need some help.
> 
> 
> thank you
> 
> 
> _______________________________________________
> mpich-discuss mailing list
> mpich-discuss at mcs.anl.gov
> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss
> _______________________________________________
> mpich-discuss mailing list
> mpich-discuss at mcs.anl.gov
> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss


More information about the mpich-discuss mailing list