Skip to main content

Oracle OCI driver / no ocijdbc10 in java.library.path

Please note these forums are being decommissioned and use the new and improved forums at
No replies
Joined: 2010-11-04

I'm trying to use the oracle instant client together with glassfish, but can't get them to work together (reliable). What i did:

- copy ojdbc6.jar to ${com.sun.aas.instanceRoot}/lib (/opt/glassfish3122/glassfish/domains/domain1/lib)
- copy native libraries to /opt/glassfish3122/glassfish/lib/native/linux64
- point LD_LIBRARY_PATH at /opt/glassfish3122/glassfish/lib/native/linux64 (only this directory)
- set this directory as native library prefix in the glassfish admin (native-library-path-prefix="${com.sun.aas.installRoot}/lib/native/linux64/")

if i restart the server, sometimes it works sometimes not, giving me an "no ocijdbc10 in java.library.path" error.

I tried both 64 and 32 bit linux variants (suse, ubuntu). I'm using the corresponding JDK (32 or 64bit) and native libraries. i'm running glassfish as root. File permissions are 777.

I'm quite stuck here, mainly because it does work sometimes and i don't know what wents wrong in the case it doesn't? any pointers, what i may try?