An Error Occurred In Mpi_init In Communicator Mpi_comm_world
Contents |
the second loop Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] Hi I have a problem, mpi_err_rank: invalid rank in the following program, at the first loop there is
An Error Occurred In Mpi_send
no error (and when I run the program with only 1 loop there is no error), but when I try to run for the second loop there is an error like this: [hx002:02844] *** An error occurred in MPI_Init [hx002:02844] *** on communicator MPI_COMM_WORLD [hx002:02844] *** MPI_ERR_OTHER: known error not in list [hx002:02844] *** MPI_ERRORS_ARE_FATAL (goodbye) [hx002:02846] *** An error occurred in MPI_Init [hx002:02846] *** on communicator MPI_COMM_WORLD [hx002:02846] *** MPI_ERR_OTHER: known error not in list [hx002:02846] *** MPI_ERRORS_ARE_FATAL (goodbye) [hx002:02847] *** An error occurred in MPI_Init [hx002:02847] *** on communicator MPI_COMM_WORLD [hx002:02847] *** MPI_ERR_OTHER: known error not in list [hx002:02847] *** MPI_ERRORS_ARE_FATAL (goodbye) [hx002:02851] *** An error occurred in MPI_Init [hx002:02851] *** on communicator MPI_COMM_WORLD [hx002:02851] *** MPI_ERR_OTHER: known error not in list [hx002:02851] *** MPI_ERRORS_ARE_FATAL (goodbye) [hx002:02845] *** An error occurred in MPI_Init [hx002:02845] *** on communicator MPI_COMM_WORLD [hx002:02845] *** MPI_ERR_OTHER: known error not in list [hx002:02845] *** MPI_ERRORS_ARE_FATAL (goodbye) [hx002:02848] *** An error occurred in MPI_Init [hx002:02848] *** on communicator MPI_COMM_WORLD [hx002:02848] *** MPI_ERR_OTHER: known error not in list [hx002:02848] *** MPI_ERRORS_ARE_FATAL (goodbye) [hx002:02849] *** An error occurred in MPI_Init [hx002:02849] *** on communicator MPI_COMM_WORLD [hx002:02849] *** MPI_ERR_OTHER: known error not in list [hx002:02849] *** MPI_ERRORS_ARE_FATAL (goodbye) [hx002:02850] *** An error occurred in MPI_Init [hx002:02850] *** on communicator MPI_COMM_WORLD [hx002:02850] *** MPI_ERR_OTHER: known error not in list [hx002:02850] *** MPI_ERRORS_ARE_FATAL (goodbye) The program is as follows: program ringtopo include 'mpif.h' integer numtasks, rank, next, prev, buf(2), tag1, tag2, ierr integer stats(MPI_STATUS_SIZE,2), reqs(2),reqs1(2) integer,parameter::buf_size=130 real CRXi(1
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up MPI_Send/ Recv communicator datatype error http://lists.mcs.anl.gov/pipermail/mpich-discuss/2011-September/010963.html up vote 1 down vote favorite I have the following basic MPI program written in Fortran 90: program sendRecv include 'mpif.h' !MPI Variables integer ierr, numProcs, procID !My variables integer dat, datRec !Init MPI call MPI_INIT ( ierr ) !Get number of processes/ cores requested call MPI_COMM_SIZE (MPI_COMM_WORLD, numProcs, ierr) !Get rank of process call MPI_COMM_RANK (MPI_COMM_WORLD, procID, ierr) if (procID .eq. 0) then dat=4 http://stackoverflow.com/questions/20975994/mpi-send-recv-communicator-datatype-error !Send num to process 1 call MPI_SEND (dat, 1, MPI_INT, 1, 0, MPI_COMM_WORLD, ierr) else if (procID .eq. 1) then !Recieve num from process 0 call MPI_RECV (datRec, 1, MPI_INT, 0, MPI_ANY_SOURCE, MPI_COMM_WORLD, MPI_STATUS_SIZE, ierr) !Display info write(*,*) "Process 1 recieved ", datRec, " from proc 0" else write(*,*)"Into else" end if !Finilise MPI call MPI_FINALIZE ( ierr ) end program sendRecv The purpose is just to send an integer from process 0 and receive and display it in process 1, but whatever i seem to try, i cannot get it to work. I am compiling and running this program with: mpif90 sendRecv.f90 -o tst mpirun -n 2 tst and am getting this: [conor-Latitude-XT2:3053] *** An error occurred in MPI_Send [conor-Latitude-XT2:3053] *** on communicator MPI_COMM_WORLD [conor-Latitude-XT2:3053] *** MPI_ERR_TYPE: invalid datatype [conor-Latitude-XT2:3053] *** MPI_ERRORS_ARE_FATAL (your MPI job will now abort) -------------------------------------------------------------------------- mpirun has exited due to process rank 1 with PID 3054 on node conor-Latitude-XT2 exiting without calling "finalize". This may have caused other processes in the application to be terminated by signals sent by mpirun (as reported here). -------------------------------------------------------------------------- [conor-Latitude-XT2:03052] 1 more process has sent help message help-mpi-errors.txt / mpi_errors_are_fatal [conor-Latitude-XT2:03052] Set MCA parameter "orte_ba
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies http://stackoverflow.com/questions/28205679/mpi-cart-create-error of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign an error up MPI_Cart_create error up vote 2 down vote favorite I've been having trouble getting the basic mpi_cart_create() function in Fortran working. The following code program main USE mpi implicit none integer :: old_comm, new_comm, ndims, ierr integer, DIMENSION(1) :: dim_size logical :: reorder logical, DIMENSION(1) :: periods call MPI_INIT(ierr) old_comm = MPI_COMM_WORLD ndims = 1 dim_size(1) = 4 periods(1) = .true. reorder an error occurred = .true. call MPI_CART_CREATE(old_comm, ndims, dim_size, periods, reorder, new_comm, ierr) call MPI_Finalize(ierr) end program Compiled with mpif90 mpitest.f90 Yields, during runtime, An error occurred in MPI_Cart_create on communicator MPI_COMM_WORLD MPI_ERR_OTHER: known error not in list MPI_ERRORS_ARE_FATAL: your MPI job will now abort This seems simple, but does anyone recognize the issue? EDIT: I updated the code (I was a bit hasty in cutting the code down before, thanks for opinting these out) to correct the problems noted below. I think I probably messed up the MPI installation though, since the code will run when compiled with (when using `use mpi`) mpif90 mpitest3.f90 mpirun -np 4 ./a.out OR (when using `include "mpif.h"`) mpifort mpitest.f90 orterun -np 4 ./a.out If I try to compile with mpifort with the use mpi statement I get PI_CART_CREATE(old_comm, ndims, dim_size, periods, reorder, new_comm, ierr) Error: There is no specific subroutine for the generic 'mpi_cart_create' at (1) And if I mix the compiler and run call (e.g. compile with mpif90 and run with orterun) I get Fatal error in PMPI_Cart_create: Invalid argument, error stack: PMPI_Cart_create(315).....: MPI_Cart_create(MPI_COMM_WORLD, ndims=1, dims=0x7fff26671130, periods=0x1c6e300, reorder=1, comm_cart=0x7fff26671124) failed MPIR_Car