-
Notifications
You must be signed in to change notification settings - Fork 398
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
Error: librdkafka.so.1: cannot open shared object file: No such file or directory #474
Comments
Here is also the output of npm install
|
Looking though the install logs, it seems to not be able to find/setup things.
|
@F483 any fix for this? I'm running into the same exact issue |
Duplicate of #405 ? |
Same issue, but only on Ubuntu 18.04. It works on Ubuntu 16.04. Very weird. |
Same issue. Downgraded to 2.3.4 and works again. |
librkafka++.so.1 not searching for librdkafka.so.1 correctly
I was able to reproduce this issue on both 16.04 & 18.04 using node-rdkafka 2.3.0 -> 2.4.1. I suspect what determines if it fails or not on ubuntu 16 vs 18 is dictated by what else maybe installed which causes a version of librdkafka.so.1 to be installed into a default lib search location. For my setup I used some lean docker containers to ensure librdkafak.so.1 was not installed. In summary what I'm seeing is node-rdkafka's dependency librdkafka++.so.1 is failing to find librkafka.so.1. In version 2.4.1 this occurs even though node-rdkafak's binding.gyp is setup with -rpath using $ORIGIN/../deps. In researching to understand this, it appears that librdkafka++.so.1 must also have its library search paths augmented. log for librdkafka++.so.1 showing failure to find library. (lines 1, 3-35, 54) log showing node-rdkafka ldd output with failure to find library. (lines 30-64, 79) For reference:
Now I'm trying to figure out how to mod node-rdkafka to have the same effect as adjusting the librdkafka project directly. |
librkafka++.so.1 not searching for librdkafka.so.1 correctly
librkafka++.so.1 not searching for librdkafka.so.1 correctly fix escaping of ORIGIN variable
I have an adjustment which appears to work, but I'm not sure if its the right final solution. It seems like this change to util/configure.js somehow allows the setting in binding.gyp (approx line 81) to take effect on the indirect dependency librdkafka.so.1. Given the nature of the change I would have expected to see the rpath added in via util/configure.js to have appeared in the log log showing effect after adjustment to util/configure.js for reference: |
Also having this problem on |
I've not had time to assemble a proper pull request to get my potential fix reviewed. The change effects the build configuration used by node-rdkafaka when building librdkafka, so you'll have to work through rebuilding node-rdkafka and deploying the adjusted version to use it. |
In the meantime you can try to fix your installation by doing this:
I've found this temporal solution here |
@mike-coolfront I tested out your fix and it solves this issue when node-rdkafka is deployed on Heroku. |
librkafka++.so.1 not searching for librdkafka.so.1 correctly fix escaping of ORIGIN variable adjust white space
quick update: for those interested here is a link to a project I cobbled together to test for the issue on node-rdkafka 2.4.2, 2.5.0 and 2.5.1 in isolated ubuntu 18 containers docker based lib path tester for node-rdkafka I'm going to get my team using 2.5.x and see if we run into the past issues again and will report back. |
@mike-coolfront thanks for the update. Confirmed: v2.5 successfully runs on Heroku (Ubuntu 18.04). |
This is essentially to solve an issue with librdkafka.so.1 lookup when running tests. It's unclear in which situation exactly it arises (it seems to run OK on the CI for example but fail in other environments) but bumping the version fixes for me and was the suggestion in Blizzard/node-rdkafka#474.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. |
Environment Information
Steps to Reproduce
It seems to install, but not sure. See install log in comment below.
The library it says it can't find does seem to have been built, is this a configuration issue?
The text was updated successfully, but these errors were encountered: