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

build/ops: deb: add python dependencies where needed #11507

Merged
merged 2 commits into from Oct 19, 2016
Merged

Conversation

smithfarm
Copy link
Contributor

@smithfarm
Copy link
Contributor Author

jenkins test this please

@smithfarm
Copy link
Contributor Author

Pretty sure the make check failure is unrelated to this PR. A quick glance shows at least one other PR suffering from the same failure: #11509

Depends: ceph-base (= ${binary:Version}), ${misc:Depends}, ${shlibs:Depends}
Depends: ceph-base (= ${binary:Version}),
${misc:Depends},
${python:Depends},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why ceph-mds depends on ${python:Depends}?

Depends: ceph-base (= ${binary:Version}), ${misc:Depends}, ${shlibs:Depends}
Depends: ceph-base (= ${binary:Version}),
${misc:Depends},
${python:Depends},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we don't run ceph-mgr through dh_python2 or dh_python3 in debian/rules yet. but since we install src/pybind/mgr, probably we should update override_dh_python3 and override_dh_python2 accordingly?

@@ -600,6 +609,7 @@ Depends: ceph-common (= ${binary:Version}),
mime-support,
librgw2 (= ${binary:Version}),
${misc:Depends},
${python:Depends},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i don't think radosgw depends on python. could you elaborate a little bit?

@smithfarm
Copy link
Contributor Author

@tchaikov Thanks for reviewing! I added a commit - does it come closer to what you are suggesting?

@smithfarm smithfarm changed the title build/ops: deb: add python dependencies where needed DNM: build/ops: deb: add python dependencies where needed Oct 16, 2016
@@ -172,6 +177,7 @@ Architecture: linux-any
Depends: ceph-base (= ${binary:Version}),
python-flask,
${misc:Depends},
${python:Depends},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@smithfarm i don't think the monitor depends on python in any way. could you remove this line?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's the whole purpose of this PR, actually. Please have a look at the tracker issue. I don't know exactly what's going on, but when only the "ceph-mon" package is installed, it is impossible to run "/usr/bin/ceph". For example:

$ ceph --version
Traceback (most recent call last):
  File "/usr/bin/ceph", line 101, in <module>
    import rados
ImportError: libpython2.7.so.1.0: cannot open shared object file: No such file or directory

Now, libpython2.7.so.1.0 is presumably in the libpython2.7 package, but that package is not getting installed when someone does "apt-get install ceph-mon". It does get installed when someone does "apt-get install ceph-osd" and ceph-osd does depend on ${python:Depends}.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@@ -150,6 +150,8 @@ override_dh_python2:
dh_python2 -p ceph-common
dh_python2 -p ceph-base
dh_python2 -p ceph-osd
dh_python2 -p ceph-mon
dh_python2 -p ceph-mgr

override_dh_python3:
for binding in rados cephfs rbd; do \
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@smithfarm could you add dh_python3 -p ceph-mgr to override_dh_python3 accordingly? and maybe we don't need to run ceph-mon through dh_python2?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added another commit. I don't have any Debian system to test this on, unfortunately.

@smithfarm
Copy link
Contributor Author

@tchaikov It would be interesting to test if libpython2.7 gets installed when someone does "apt-get install ceph-common" (since /usr/bin/ceph is in the ceph-common package, that's where libpython2.7 should be getting pulled in as a dependency, but apparently isn't).

@tchaikov
Copy link
Contributor

tchaikov commented Oct 19, 2016

@smithfarm i updated your commits with the changes in my mind, squashed the related ones, and pushed to https://github.com/tchaikov/ceph/tree/wip-11507, does it make sense to you?

@smithfarm
Copy link
Contributor Author

@tchaikov The commit is missing Signed-off-by: Kefu Chai . . . :-)

@tchaikov
Copy link
Contributor

@smithfarm i updated https://github.com/tchaikov/ceph/commits/wip-11507 to address your comment, and pushed to the branch you are using =)

@tchaikov tchaikov changed the title DNM: build/ops: deb: add python dependencies where needed build/ops: deb: add python dependencies where needed Oct 19, 2016
@smithfarm
Copy link
Contributor Author

Now the unrelated failing test is 123 - unittest_bluestore_types

@alfredodeza
Copy link
Contributor

I was able to install ceph-mon with this branch and not get into issues. This needs to be rebased though, I am not seeing other fixes that were recently merged that prevent this:

$ ceph --version
ceph version HEAD-HASH-NOTFOUND (GITDIR-NOTFOUND)

Signed-off-by: Nathan Cutler <ncutler@suse.com>
this reverts 48f4576 and f140a8c

Fixes: http://tracker.ceph.com/issues/17579
Signed-off-by: Nathan Cutler <ncutler@suse.com>
Signed-off-by: Kefu Chai <kchai@redhat.com>
@smithfarm
Copy link
Contributor Author

Rebased.

@alfredodeza alfredodeza merged commit bfc90da into master Oct 19, 2016
@alfredodeza alfredodeza deleted the wip-17579 branch October 19, 2016 12:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants