Project

General

Profile

Bug #16640

libcephfs: Java bindings failing to load on CentOS

Added by John Spray over 2 years ago. Updated 8 months ago.

Status:
New
Priority:
Low
Assignee:
-
Category:
Hadoop
Target version:
Start date:
07/08/2016
Due date:
% Done:

0%

Source:
other
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Component(FS):
Hadoop/Java
Labels (FS):
Pull request ID:

Description

http://qa-proxy.ceph.com/teuthology/jspray-2016-07-08_05:19:56-fs-master-distro-basic-mira/302088/teuthology.log

2016-07-08T11:28:40.273 INFO:tasks.workunit.client.0.mira030.stdout:JUnit version 4.11
2016-07-08T11:28:40.497 INFO:tasks.workunit.client.0.mira030.stdout:.Loading libcephfs-jni from default path: /usr/lib/jni:/usr/lib64
2016-07-08T11:28:40.498 INFO:tasks.workunit.client.0.mira030.stdout:Loading libcephfs-jni: /usr/lib64/libcephfs_jni.so
2016-07-08T11:28:40.498 INFO:tasks.workunit.client.0.mira030.stdout:Loading libcephfs-jni: /usr/lib/jni/libcephfs_jni.so
2016-07-08T11:28:40.498 INFO:tasks.workunit.client.0.mira030.stdout:Loading libcephfs-jni: Failure!
2016-07-08T11:28:40.578 INFO:tasks.workunit.client.0.mira030.stdout:E.EEE.E.E.E.E.E.E.E.E.E.E.E.E.E.E.E.E.E.E.E.E.E.E.E.E.E
2016-07-08T11:28:40.633 INFO:tasks.workunit.client.0.mira030.stdout:Time: 0.105
2016-07-08T11:28:40.633 INFO:tasks.workunit.client.0.mira030.stdout:There were 29 failures:
2016-07-08T11:28:40.634 INFO:tasks.workunit.client.0.mira030.stdout:1) test_double_mount(com.ceph.fs.CephDoubleMountTest)
2016-07-08T11:28:40.639 INFO:tasks.workunit.client.0.mira030.stdout:java.lang.Exception: Unexpected exception, expected<com.ceph.fs.CephAlreadyMountedException> but was<java.lang.UnsatisfiedLinkError>

I am suspicious that this might have broken in the transition to cmake built packages


Related issues

Duplicated by fs - Bug #16876: java.lang.UnsatisfiedLinkError: Can't load library: /usr/lib/jni/libcephfs_jni.so Duplicate 07/31/2016

History

#1 Updated by John Spray over 2 years ago

  • Category set to Hadoop

#2 Updated by Noah Watkins over 2 years ago

I saw this before with Debian. It looks like it's now showing with with rhelish stuff. The non-devel package includes the libraries with the version suffix, but the Java bindings look for the library without the version name, which is provided by the -devel package. Looks like solution is to install the -devel package. On a related note, what is the purpose of the non-versioned libraries?

[nwatkins@sapporo ~]$ rpm -qlp Downloads/libcephfs_jni1-11.0.0-411.g5c2a1bb.x86_64.rpm 
warning: Downloads/libcephfs_jni1-11.0.0-411.g5c2a1bb.x86_64.rpm: Header V4 DSA/SHA1 Signature, key ID 03c3951a: NOKEY
/usr/lib64/libcephfs_jni.so.1
/usr/lib64/libcephfs_jni.so.1.0.0
[nwatkins@sapporo ~]$ rpm -qlp Downloads/libcephfs_jni1-devel-11.0.0-411.g5c2a1bb.x86_64.rpm 
warning: Downloads/libcephfs_jni1-devel-11.0.0-411.g5c2a1bb.x86_64.rpm: Header V4 DSA/SHA1 Signature, key ID 03c3951a: NOKEY
/usr/lib64/libcephfs_jni.so

#3 Updated by Greg Farnum over 2 years ago

  • Component(FS) Hadoop/Java added

#4 Updated by John Spray over 2 years ago

I suppose the convention of putting the unversioned libraries into -dev packages is based on the idea that built code should always be pointing to versioned ones?

I can't see why the java bindings would have previously pointed to a versioned library from the Makefile.am/CMakeLists.txt difference, but I'm not very familiar with this code. To get past the test failure I've created a teuthology change to install the -dev library https://github.com/ceph/teuthology/pull/907

The real fix for this is probably going to be to figure out the build issue such that users don't have to install -dev libraries.

#5 Updated by Greg Farnum over 2 years ago

  • Status changed from New to Resolved
  • Assignee set to John Spray

#6 Updated by Ken Dreyer over 2 years ago

Noah, John, I'm guessing the Java bindings ought to link to the versioned libcephfs_jni.so.1.0.0 instead of the unversioned libcephfs_jni.so? Is that right?

#7 Updated by John Spray over 2 years ago

  • Status changed from Resolved to New

Let's leave this open to work out if there is a change to the build we can make to avoid the java bindings requiring a -dev package at runtime

#8 Updated by John Spray over 2 years ago

  • Duplicated by Bug #16876: java.lang.UnsatisfiedLinkError: Can't load library: /usr/lib/jni/libcephfs_jni.so added

#9 Updated by Jeff Layton over 2 years ago

Yes, you really don't want to load the unversioned library at runtime. It's possible that you'll end up picking up a newer version of the library that doesn't have the correct ABI, which can lead to all sorts of weird problems that are difficult to troubleshoot.

#10 Updated by John Spray over 2 years ago

So, the PR had a passing test run:
https://github.com/ceph/ceph-qa-suite/pull/1084
http://pulpito.ceph.com/jspray-2016-07-29_06:53:13-fs:basic-master-distro-basic-mira/

...but we're still seeing the issue:
http://qa-proxy.ceph.com/teuthology/teuthology-2016-08-07_02:10:02-fs-jewel---basic-smithi/353311/

From the passes and fails I can see, this seems to still be failing on CentOS and passing on Ubuntu.

#11 Updated by John Spray over 2 years ago

  • Priority changed from Normal to Urgent

#12 Updated by John Spray over 2 years ago

  • Subject changed from libcephfs Java bindings failing to load to libcephfs Java bindings failing to load on CentOS

#13 Updated by John Spray about 2 years ago

Temporarily pinning tests to Ubuntu: https://github.com/ceph/ceph-qa-suite/pull/1186

#15 Updated by John Spray about 2 years ago

  • Assignee deleted (John Spray)

#16 Updated by Patrick Donnelly 8 months ago

  • Subject changed from libcephfs Java bindings failing to load on CentOS to libcephfs: Java bindings failing to load on CentOS
  • Priority changed from Urgent to Low
  • Target version set to v14.0.0

Also available in: Atom PDF