Linux系统下mpi 编程出现:Signal: Segmentation fault, Signal code: Address not mapped

在Ubuntu(安装了mpich和openmpi)下MPI编程时,代码没问题,但是在mpirun运行的时候出现如下问题
[ubuntu:04803] *** Process received signal *** [ubuntu:04803] Signal: Segmentation fault (11) [ubuntu:04803] Signal code: Address not mapped (1) [ubuntu:04803] Failing at address: 0x7548d0c [ubuntu:04803] [ 0] [0x86b410] [ubuntu:04803] [ 1] /lib/tls/i686/cmov/libc.so.6(fclose+0x1a0) [0x186b00] [ubuntu:04803] [ 2] ./exmpi_2(main+0x78e) [0x80492c2] [ubuntu:04803] [ 3] /lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe6) [0x141bd6] [ubuntu:04803] [ 4] ./exmpi_2() [0x8048aa1] [ubuntu:04803] *** End of error message ***

折腾了半天,最后删掉了openmpi
sudo apt-get remove  libopenmpi-dev openmpi-bin

   安装mpich 

sudo apt-get install  libmpich-dev openmpi-bin

  一切搞定!!!

 

转载于:https://www.cnblogs.com/kuangsyx/p/8048012.html

你可能感兴趣的:(Linux系统下mpi 编程出现:Signal: Segmentation fault, Signal code: Address not mapped)