-
Notifications
You must be signed in to change notification settings - Fork 131
Closed
Description
Hi,
I have used mpi4py with Intel MPI in the past. I am now trying to use on a fresh Ubuntu 22.04.1 LTS with Intel MP andh mpi4py 3.1.4 and get the following error upon trying to import MPI:
~/mpi4py/mpi4py-3.1.4 $ python demo/helloworld.py
Abort(1090959) on node 0 (rank 0 in comm 0): Fatal error in PMPI_Init_thread: Other MPI error, error stack:
MPIR_Init_thread(176)........:
MPID_Init(1538)..............:
MPIDI_OFI_mpi_init_hook(1473):
(unknown)(): Other MPI error
[unset]: write_line error; fd=-1 buf=:cmd=abort exitcode=1090959
:
system msg for write_line failure : Bad file descriptor
Abort(1090959) on node 0 (rank 0 in comm 0): Fatal error in PMPI_Init_thread: Other MPI error, error stack:
MPIR_Init_thread(176)........:
MPID_Init(1538)..............:
MPIDI_OFI_mpi_init_hook(1473):
(unknown)(): Other MPI error
[unset]: write_line error; fd=-1 buf=:cmd=abort exitcode=1090959
:
system msg for write_line failure : Bad file descriptor
Segmentation fault (core dumped)Here is how I am set up:
Intel MPI
Intel MPI is installed through the OneAPI package:
$ mpicc -v
mpigcc for the Intel(R) MPI Library 2021.7 for Linux*
Copyright Intel Corporation.
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/11/lto-wrapper
OFFLOAD_TARGET_NAMES=nvptx-none:amdgcn-amdhsa
OFFLOAD_TARGET_DEFAULT=1
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 11.3.0-1ubuntu1~22.04' --with-bugurl=file:///usr/share/doc/gcc-11/README.Bugs --enable-languages=c,ada,c++,go,brig,d,fortran,objc,obj-c++,m2 --prefix=/usr --with-gcc-major-version-only --program-suffix=-11 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-bootstrap --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-plugin --enable-default-pie --with-system-zlib --enable-libphobos-checking=release --with-target-system-zlib=auto --enable-objc-gc=auto --enable-multiarch --disable-werror --enable-cet --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none=/build/gcc-11-xKiWfi/gcc-11-11.3.0/debian/tmp-nvptx/usr,amdgcn-amdhsa=/build/gcc-11-xKiWfi/gcc-11-11.3.0/debian/tmp-gcn/usr --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu --with-build-config=bootstrap-lto-lean --enable-link-serialization=2
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 11.3.0 (Ubuntu 11.3.0-1ubuntu1~22.04)I can confirm that Intel MPI is working with their test programs:
$ mpirun -n 4 -ppn 1 -f mpihosts.txt ./myprog
Hello world: rank 0 of 4 running on intel01
Hello world: rank 1 of 4 running on intel02
Hello world: rank 2 of 4 running on intel03
Hello world: rank 3 of 4 running on intel04
As well as:
$ mpiexec -n 4 -perhost 1 -hostfile mpihosts.txt -prepend-rank echo test
[1] test
[3] test
[2] test
[0] test
mpi4py install
I have installed mpi4py 3.1.4 by downloading the release and setting up mpi.cfg as follows:
# Default configuration
# ---------------------
[mpi]
mpi_dir = /opt/intel/oneapi/mpi/latest/
mpicc = %(mpi_dir)s/bin/mpicc
mpicxx = %(mpi_dir)s/bin/mpicxx
include_dirs = %(mpi_dir)s/include
libraries = mpi
library_dirs = %(mpi_dir)s/lib:%(mpi_dir)s/lib/release
#library_dirs = %(mpi_dir)s/lib/release
runtime_library_dirs = %(mpi_dir)s/lib
python setup.py build
python setup.py installThen in a Python interpreter (Python 3.9.12 (main, Apr 5 2022, 06:56:58)), I get this:
>>> import mpi4py
>>> mpi4py.__version__
'3.1.4'
>>> mpi4py.get_config()
{'mpicc': '/opt/intel/oneapi/mpi/latest//bin/mpicc', 'mpicxx': '/opt/intel/oneapi/mpi/latest//bin/mpicxx', 'include_dirs': '/opt/intel/oneapi/mpi/latest//include', 'libraries': 'mpi', 'library_dirs': '/opt/intel/oneapi/mpi/latest//lib:/opt/intel/oneapi/mpi/latest//lib/release', 'runtime_library_dirs': '/opt/intel/oneapi/mpi/latest//lib'}
>>> from mpi4py import MPI
Abort(1090959) on node 0 (rank 0 in comm 0): Fatal error in PMPI_Init_thread: Other MPI error, error stack:
MPIR_Init_thread(176)........:
MPID_Init(1538)..............:
MPIDI_OFI_mpi_init_hook(1473):
(unknown)(): Other MPI error
[unset]: write_line error; fd=-1 buf=:cmd=abort exitcode=1090959
:
system msg for write_line failure : Bad file descriptor
Abort(1090959) on node 0 (rank 0 in comm 0): Fatal error in PMPI_Init_thread: Other MPI error, error stack:
MPIR_Init_thread(176)........:
MPID_Init(1538)..............:
MPIDI_OFI_mpi_init_hook(1473):
(unknown)(): Other MPI error
[unset]: write_line error; fd=-1 buf=:cmd=abort exitcode=1090959
:
system msg for write_line failure : Bad file descriptor
Segmentation fault (core dumped)Thank you for your help
Metadata
Metadata
Assignees
Labels
No labels