This is run with PETSc opt mode, so the error message looks not very useful, see below: Probably I should use dbg version to see the details.
[0]PETSC ERROR: ------------------------------------------------------------------------ [0]PETSC ERROR: Caught signal number 11 SEGV: Segmentation Violation, probably memory access out of range [0]PETSC ERROR: Try option -start_in_debugger or -on_error_attach_debugger [0]PETSC ERROR: or see http://www.mcs.anl.gov/petsc/documentation/faq.html#valgrind [0]PETSC ERROR: or try http://valgrind.org on GNU/linux and Apple Mac OS X to find memory corruption errors [0]PETSC ERROR: configure using --with-debugging=yes, recompile, link, and run [0]PETSC ERROR: to get more information on the crash. [1]PETSC ERROR: ------------------------------------------------------------------------ [1]PETSC ERROR: Caught signal number 11 SEGV: Segmentation Violation, probably memory access out of range [1]PETSC ERROR: Try option -start_in_debugger or -on_error_attach_debugger [1]PETSC ERROR: or see http://www.mcs.anl.gov/petsc/documentation/faq.html#valgrind [1]PETSC ERROR: or try http://valgrind.org on GNU/linux and Apple Mac OS X to find memory corruption errors [1]PETSC ERROR: configure using --with-debugging=yes, recompile, link, and run [2]PETSC ERROR: ------------------------------------------------------------------------ [2]PETSC ERROR: Caught signal number 11 SEGV: Segmentation Violation, probably memory access out of range [2]PETSC ERROR: Try option -start_in_debugger or -on_error_attach_debugger [2]PETSC ERROR: or see http://www.mcs.anl.gov/petsc/documentation/faq.html#valgrind [2]PETSC ERROR: or try http://valgrind.org on GNU/linux and Apple Mac OS X to find memory corruption errors [2]PETSC ERROR: configure using --with-debugging=yes, recompile, link, and run [2]PETSC ERROR: [1]PETSC ERROR: to get more information on the crash. to get more information on the crash. [3]PETSC ERROR: ------------------------------------------------------------------------ [3]PETSC ERROR: Caught signal number 11 SEGV: Segmentation Violation, probably memory access out of range [3]PETSC ERROR: Try option -start_in_debugger or -on_error_attach_debugger [3]PETSC ERROR: or see http://www.mcs.anl.gov/petsc/documentation/faq.html#valgrind [3]PETSC ERROR: or try http://valgrind.org on GNU/linux and Apple Mac OS X to find memory corruption errors [3]PETSC ERROR: configure using --with-debugging=yes, recompile, link, and run [3]PETSC ERROR: to get more information on the crash. [0]PETSC ERROR: --------------------- Error Message -------------------------------------------------------------- [0]PETSC ERROR: Signal received [0]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for trouble shooting. [0]PETSC ERROR: Petsc Release Version 3.5.4, May, 23, 2015 [0]PETSC ERROR: ./example-opt on a arch-darwin-c-opt named mcswl164.mcs.anl.gov by xzhao Mon Aug 17 11:20:33 2015 [0]PETSC ERROR: Configure options --with-cc=gcc-4.9 --with-cxx=g++-4.9 --with-fc=gfortran-4.9 --with-cxx-dialect=C++11 --download-mpich --download-fblaslapack --download-scalapack --download-mumps --download-superlu_dist --download-hypre --download-ml --download-parmetis --download-metis --download-triangle --download-chaco --download-elemental --with-debugging=0 [0]PETSC ERROR: #1 User provided function() line 0 in unknown file [1]PETSC ERROR: --------------------- Error Message -------------------------------------------------------------- [1]PETSC ERROR: Signal received [1]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for trouble shooting. [1]PETSC ERROR: Petsc Release Version 3.5.4, May, 23, 2015 [1]PETSC ERROR: ./example-opt on a arch-darwin-c-opt named mcswl164.mcs.anl.gov by xzhao Mon Aug 17 11:20:33 2015 [1]PETSC ERROR: Configure options --with-cc=gcc-4.9 --with-cxx=g++-4.9 --with-fc=gfortran-4.9 --with-cxx-dialect=C++11 --download-mpich --download-fblaslapack --download-scalapack --download-mumps --download-superlu_dist --download-hypre --download-ml --download-parmetis --download-metis --download-triangle --download-chaco --download-elemental --with-debugging=0 [1]PETSC ERROR: #1 User provided function() line 0 in unknown file [2]PETSC ERROR: --------------------- Error Message -------------------------------------------------------------- [2]PETSC ERROR: Signal received [2]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for trouble shooting. [2]PETSC ERROR: Petsc Release Version 3.5.4, May, 23, 2015 [2]PETSC ERROR: ./example-opt on a arch-darwin-c-opt named mcswl164.mcs.anl.gov by xzhao Mon Aug 17 11:20:33 2015 [2]PETSC ERROR: Configure options --with-cc=gcc-4.9 --with-cxx=g++-4.9 --with-fc=gfortran-4.9 --with-cxx-dialect=C++11 --download-mpich --download-fblaslapack --download-scalapack --download-mumps --download-superlu_dist --download-hypre --download-ml --download-parmetis --download-metis --download-triangle --download-chaco --download-elemental --with-debugging=0 [2]PETSC ERROR: #1 User provided function() line 0 in unknown file [3]PETSC ERROR: --------------------- Error Message -------------------------------------------------------------- [3]PETSC ERROR: Signal received [3]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for trouble shooting. [3]PETSC ERROR: Petsc Release Version 3.5.4, May, 23, 2015 [3]PETSC ERROR: ./example-opt on a arch-darwin-c-opt named mcswl164.mcs.anl.gov by xzhao Mon Aug 17 11:20:33 2015 [3]PETSC ERROR: Configure options --with-cc=gcc-4.9 --with-cxx=g++-4.9 --with-fc=gfortran-4.9 --with-cxx-dialect=C++11 --download-mpich --download-fblaslapack --download-scalapack --download-mumps --download-superlu_dist --download-hypre --download-ml --download-parmetis --download-metis --download-triangle --download-chaco --download-elemental --with-debugging=0 [3]PETSC ERROR: #1 User provided function() line 0 in unknown file application called MPI_Abort(MPI_COMM_WORLD, 59) - process 0 application called MPI_Abort(MPI_COMM_WORLD, 59) - process 1 application called MPI_Abort(MPI_COMM_WORLD, 59) - process 2 [cli_0]: aborting job: application called MPI_Abort(MPI_COMM_WORLD, 59) - process 0 [cli_1]: aborting job: application called MPI_Abort(MPI_COMM_WORLD, 59) - process 1 [cli_2]: aborting job: application called MPI_Abort(MPI_COMM_WORLD, 59) - process 2 application called MPI_Abort(MPI_COMM_WORLD, 59) - process 3 [cli_3]: aborting job: application called MPI_Abort(MPI_COMM_WORLD, 59) - process 3 On Mon, Aug 17, 2015 at 11:16 AM, Dmitry Karpeyev <[email protected]> wrote: > Xujun, > Regarding your original question: please send the complete error message. > Dmitry. > > On Mon, Aug 17, 2015 at 11:15 AM Xujun Zhao <[email protected]> wrote: > >> Ahhhh, I should drink some coffee in the morning. >> Now it passed the test! >> >> On Mon, Aug 17, 2015 at 11:13 AM, Matthew Knepley <[email protected]> >> wrote: >> >>> On Mon, Aug 17, 2015 at 11:02 AM, Xujun Zhao <[email protected]> wrote: >>> >>>> No. It gives the following error msg: >>>> >>> >>> Did you build the executable? >>> >>> cd src/vec/vec/examples/tutorials >>> make ex43 >>> >>> Matt >>> >>> >>>> mpirun -np 2 ex43 >>>> >>>> [proxy:0:[email protected]] [proxy:0:[email protected]] >>>> HYDU_create_process (utils/launch/launch.c:75): HYDU_create_process >>>> (utils/launch/launch.c:75): execvp error on file ex43 (No such file or >>>> directory) >>>> >>>> execvp error on file ex43 (No such file or directory) >>>> >>>> On Mon, Aug 17, 2015 at 10:57 AM, Matthew Knepley <[email protected]> >>>> wrote: >>>> >>>>> On Mon, Aug 17, 2015 at 10:49 AM, Xujun Zhao <[email protected]> >>>>> wrote: >>>>> >>>>>> Hi all, >>>>>> >>>>>> I want PETSc to generate random vector using VecSetRandom() following >>>>>> given examples, but failed and showed some "out of memory" error. The >>>>>> following is the code, which goes well until it reaches VecSetRandom(). >>>>>> Can >>>>>> anyone help me figure out the reason? Thanks a lot. >>>>>> >>>>> >>>>> Does src/vec/vec/examples/tests/ex43.c run for you? >>>>> >>>>> Thanks, >>>>> >>>>> Matt >>>>> >>>>> >>>>>> XZ >>>>>> >>>>>> >>>>>> >>>>>> -------------------------------------------------------------------------------------------- >>>>>> Vec u; >>>>>> PetscRandom rand_ctx; /* random number generator context */ >>>>>> PetscMPIInt size, rank; >>>>>> PetscInt n, dn; >>>>>> >>>>>> >>>>>> MPI_Comm_rank(PETSC_COMM_WORLD,&rank);//CHKERRQ(ierr); >>>>>> MPI_Comm_size(PETSC_COMM_WORLD,&size);//CHKERRQ(ierr); >>>>>> n = N/size + 1; >>>>>> dn = n*size - N; >>>>>> if ( dn>0 && rank<dn ) n -= 1; >>>>>> printf("--->test in petsc_random_vector(): rank = %d, n = >>>>>> %d\n",rank,n); >>>>>> >>>>>> >>>>>> VecCreate(PETSC_COMM_WORLD,&u); >>>>>> VecSetSizes(u,n,N); >>>>>> PetscRandomCreate(PETSC_COMM_WORLD, &rand_ctx); >>>>>> #if defined(PETSC_HAVE_DRAND48) >>>>>> PetscRandomSetType(rand_ctx,PETSCRAND48); >>>>>> #elif defined(PETSC_HAVE_RAND) >>>>>> PetscRandomSetType(rand_ctx,PETSCRAND); >>>>>> #endif >>>>>> PetscRandomSetFromOptions(rand_ctx); >>>>>> >>>>>> >>>>>> VecSetRandom(u,rand_ctx); >>>>>> PetscRandomDestroy(&rand_ctx); >>>>>> >>>>> >>>>> >>>>> >>>>> -- >>>>> What most experimenters take for granted before they begin their >>>>> experiments is infinitely more interesting than any results to which their >>>>> experiments lead. >>>>> -- Norbert Wiener >>>>> >>>> >>>> >>> >>> >>> -- >>> What most experimenters take for granted before they begin their >>> experiments is infinitely more interesting than any results to which their >>> experiments lead. >>> -- Norbert Wiener >>> >> >>
