Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

import h5py initializes mpi prematurely #1081

Closed
robnagler opened this issue Aug 16, 2018 · 2 comments · Fixed by #1117
Closed

import h5py initializes mpi prematurely #1081

robnagler opened this issue Aug 16, 2018 · 2 comments · Fixed by #1117
Milestone

Comments

@robnagler
Copy link

robnagler commented Aug 16, 2018

importing h5py inits mpi which then starts orted:

$ python -c 'import h5py, os; os.system("ps -x|grep orted")'
12485 pts/6    Sl+    0:00 python -c import h5py, os; os.system("ps -x|grep orted")
12530 ?        Ssl    0:00 orted --hnp --set-sid --report-uri 11 --singleton-died-pipe 12 -mca state_novm_select 1
12543 pts/6    S+     0:00 sh -c ps -x|grep orted
12545 pts/6    S+     0:00 grep orted

orted inherits the parent's open files so the open sockets are a mess:

$ lsof -i -P
COMMAND     PID    USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
sirepo    12630 vagrant    3u  IPv4 379187      0t0  TCP *:8000 (LISTEN)
sirepo    12630 vagrant   24u  IPv4 379177      0t0  TCP *:1024 (LISTEN)
orted     12678 vagrant   16u  IPv4 378655      0t0  TCP *:51099 (LISTEN)
python2.7 12688 vagrant    3u  IPv4 379187      0t0  TCP *:8000 (LISTEN)
python2.7 12688 vagrant    4u  IPv4 379187      0t0  TCP *:8000 (LISTEN)
python2.7 12688 vagrant   24u  IPv4 379177      0t0  TCP *:1024 (LISTEN)
python2.7 12688 vagrant   30u  IPv4 379191      0t0  TCP *:1025 (LISTEN)
orted     12692 vagrant    3u  IPv4 379187      0t0  TCP *:8000 (LISTEN)
orted     12692 vagrant   19u  IPv4 378672      0t0  TCP *:39617 (LISTEN)
orted     12692 vagrant   24u  IPv4 379177      0t0  TCP *:1024 (LISTEN)

To assist reproducing bugs, please include the following:

  • Operating System (e.g. Windows 10, MacOS 10.11, Ubuntu 16.04.2 LTS, CentOS 7)
    Fedora 27
  • Python version (e.g. 2.7, 3.5)
    2.7.14
  • Where Python was acquired (e.g. system Python on MacOS or Linux, Anaconda on
    Windows)
    pyenv
  • h5py version (e.g. 2.6)
    2.8.0
  • HDF5 version (e.g. 1.8.17)
    hdf5-openmpi-static-1.8.18-11.fc27.x86_64
    hdf5-1.8.18-11.fc27.x86_64
    hdf5-openmpi-devel-1.8.18-11.fc27.x86_64
    hdf5-devel-1.8.18-11.fc27.x86_64
    hdf5-openmpi-1.8.18-11.fc27.x86_64
  • The full traceback/stack trace shown (if it appears)
    n/a

python -c 'import h5py; print(h5py.version.info)'

python -c 'import h5py; print(h5py.version.info)'
Summary of the h5py configuration
---------------------------------

h5py    2.8.0
HDF5    1.8.18
Python  2.7.14 (default, Jul  7 2018, 02:04:27)
[GCC 7.3.1 20180303 (Red Hat 7.3.1-5)]
sys.platform    linux2
sys.maxsize     9223372036854775807
numpy   1.14.5

where python should be substituted for the path to python used to install
h5py with.

@tacaswell
Copy link
Member

This seems to be related to #1079 ?

@1313e
Copy link

1313e commented Aug 30, 2018

Could indeed be related to the issue I raised in #1079 , which would explain the warning that I am getting there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants