kubo / ruby-oci8

Ruby-oci8 - Oracle interface for ruby
Other
169 stars 75 forks source link

ERROR: ActiveRecord oracle_enhanced adapter could not load ruby-oci8 library. Please install ruby-oci8 gem. #177

Closed bighenry69 closed 6 years ago

bighenry69 commented 6 years ago

Hi, I have installed ruby 1.9.3p551 with rvm and rails 3.1.0. I use oracle_enhanced adapter 1.4.0 and ruby-oci8 2.0.4 in order to publish an existing web application. If I run the web application with rails server on port 3000 it works normally on localhost:3000, but if I publish the app with Apache + Passenger I have the error in the subject.

Can you help me?

Thanks

kubo commented 6 years ago

Could you change these lines as those in the latest version and get the error message again? I cannot say anything without e.message.

bighenry69 commented 6 years ago

Here the error: ERROR: 'libclntsh.so.11.1: cannot open shared object file: No such file or directory - /usr/local/rvm/gems/ruby-1.9.3-p551/gems/ruby-oci8-2.0.6/lib/oci8lib_191.so'. ActiveRecord oracle_enhanced adapter could not load ruby-oci8 library. You may need install ruby-oci8 gem. (LoadError)

kubo commented 6 years ago

oci8lib_191.so could not find libclntsh.so.11.1. The environment variable LD_LIBRARY_PATH isn't set in the Passenger process. See https://github.com/rsim/oracle-enhanced#what-to-do-if-oracle-enhanced-adapter-is-not-working-with-phusion-passenger

bighenry69 commented 6 years ago

That works! Thanks a lot!