Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Unsatisfied link error with iAnywhere JDBC and Leopard

10 views
Skip to first unread message

Bill Williams

unread,
Apr 3, 2009, 1:14:28 PM4/3/09
to
I get the following error when I try to access the database using the
iAnywhere JDBC driver:

Exception in thread "main" java.lang.UnsatisfiedLinkError:
/Applications/SQLAnywhere10/System/lib32/libdbjodbc10.dylib:

If I use the jConnect JDBC driver, everything works fine.

I am able to use dbisql and sybase central; however, I do have to run
these from a console window after the sa_config.sh script has been ran.
I am trying to run my java program from the same console window where
dbisql and sybase central work from.

I have checked and the library directory is in the path:

DYLD_LIBRARY_PATH=/Applications/SQLAnywhere10/System/lib32:

Any ideas?

Thanks

Ray Ruvinskiy [Sybase iAnywhere]

unread,
Apr 3, 2009, 1:58:56 PM4/3/09
to
Hi Bill,

How are you launching this java program? Is it an application bundle
that you're running 'open' on, or are you explicitly invoking the java
executable?

Ray

Bill Williams wrote:
> It occurred to me the exception dump may help:


>
> Exception in thread "main" java.lang.UnsatisfiedLinkError:
> /Applications/SQLAnywhere10/System/lib32/libdbjodbc10.dylib:

> at java.lang.ClassLoader$NativeLibrary.load(Native Method)
> at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1822)
> at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1739)
> at java.lang.Runtime.loadLibrary0(Runtime.java:823)
> at java.lang.System.loadLibrary(System.java:1030)
> at ianywhere.ml.jdbcodbc.IDriver.try_load(IDriver.java:284)
> at ianywhere.ml.jdbcodbc.IDriver.<clinit>(IDriver.java:257)
> at java.lang.Class.forName0(Native Method)
> at java.lang.Class.forName(Class.java:169)
> at
> Library.Database.DbConnectionManager.installDriver(DbConnectionManager.java:485)
>
> at
> Library.Database.DbConnectionManager.registerConnection(DbConnectionManager.java:206)
>
> at Products.QcApp.Config.registerDbConnections(Config.java:272)
> at Products.QcApp.Config.load(Config.java:132)
> at Products.QcApp.QcApp.qcAppMain(QcApp.java:170)
> at WaveMgr.WaveMgr.main(WaveMgr.java:71)

Bill Williams

unread,
Apr 3, 2009, 1:39:43 PM4/3/09
to
It occurred to me the exception dump may help:

Exception in thread "main" java.lang.UnsatisfiedLinkError:
/Applications/SQLAnywhere10/System/lib32/libdbjodbc10.dylib:


at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1822)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1739)
at java.lang.Runtime.loadLibrary0(Runtime.java:823)
at java.lang.System.loadLibrary(System.java:1030)
at ianywhere.ml.jdbcodbc.IDriver.try_load(IDriver.java:284)
at ianywhere.ml.jdbcodbc.IDriver.<clinit>(IDriver.java:257)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:169)
at
Library.Database.DbConnectionManager.installDriver(DbConnectionManager.java:485)
at
Library.Database.DbConnectionManager.registerConnection(DbConnectionManager.java:206)
at Products.QcApp.Config.registerDbConnections(Config.java:272)
at Products.QcApp.Config.load(Config.java:132)
at Products.QcApp.QcApp.qcAppMain(QcApp.java:170)
at WaveMgr.WaveMgr.main(WaveMgr.java:71)

Bill Williams

unread,
Apr 3, 2009, 2:34:52 PM4/3/09
to
I am invoking the java program from the command line of a terminal session.

Ray Ruvinskiy [Sybase iAnywhere]

unread,
Apr 3, 2009, 2:49:01 PM4/3/09
to
This is probably not the issue, but you could try removing the trailing
colon from the value of DYLD_LIBRARY_PATH (i.e., set it to
/Applications/SQLAnywhere10/System/lib32 as opposed to
/Applications/SQLAnywhere10/System/lib32:).

Is this program something you've written, that is, can you add trace to
the source code? If you can, can you print out the value of
System.getenv("DYLD_LIBRARY_PATH")? Is this program publicly available
(could I try running it)?

Finally, could you post the command line you use to start this program
from the shell?

Thanks,

Ray

Bill Williams

unread,
Apr 3, 2009, 3:23:17 PM4/3/09
to
I tried changing DYLD_LIBRARY_PATH like you suggested and it did not help.

The program is one we have written and I can't simply post it.

Here's my command line: java WaveMgr.WaveMgr -r -t 0xff431

We have the ability to dump the environment the program is executing in
so I switched it over to use jConnect so it would run and then I dumped
it. Here is the entire thing:

Apple_PubSub_Socket_Render /tmp/launch-CYh4kk/Render
BASE_DEVDIR /mnt/data/qc/Develop
BASE_PRODUCTS /mnt/data/qc/Products
BASE_PROJECTS /mnt/data/qc/Projects
BRANCHES /mnt/data/qc/Branches
BYTE_ORDER true
CLASSPATH
/mnt/data/qc/Sandboxes/wlw/Projects/Tupperware/Classes/1.6:./:/mnt/data/qc/Projects/Tupperware/Classes/1.6:/mnt/data/qc/Projects/Tupperware/Src/Screens/Classes/1.6:/mnt/data/qc/Products/Classes/JarFiles/java-getopt-1.0.9.jar:/mnt/data/qc/Products/Classes/JarFiles/jhall.jar:/mnt/data/qc/Products/Classes/JarFiles/activation.jar:/mnt/data/qc/Products/Classes/JarFiles/mail.jar:/mnt/data/qc/Products/Classes/JarFiles/jconn2.jar:/Applications/SQLAnywhere10/System/java/jodbc.jar:/mnt/data/qc/Products/Classes/JarFiles/ojdbc14.jar:/mnt/data/qc/Products/Classes/JarFiles/msbase.jar:/mnt/data/qc/Products/Classes/JarFiles/mssqlserver.jar:/mnt/data/qc/Products/Classes/JarFiles/msutil.jar:/mnt/data/qc/Sandboxes/wlw/Products/Classes/1.6:/mnt/data/qc/Products/Classes/1.6
COMMAND_MODE unix2003
COMPILER GNU
COMPILER_ENV MacOS
CONFIG_DIR
/mnt/data/qc/Projects/Tupperware/System/Config
DATABASE_MACHINE marina
DATABASE_NAME Tupperware
DATABASE_PORT 50000
DATABASE_TYPE SYBASE8
DEVDEFAULTS
/mnt/data/qc/Sandboxes/wlw/Develop/Src/.defaults
DEVDIR /mnt/data/qc/Sandboxes/wlw/Develop
DISPLAY /tmp/launch-84B5Jq/:0
DYLD_BIND_AT_LAUNCH 1
DYLD_LIBRARY_PATH /Applications/SQLAnywhere10/System/lib32
FTP_DIR /mnt/data/qc/Projects/Tupperware/System/Ftp
FTP_INCOMING_ARCHIVE_DIR
/mnt/data/qc/Projects/Tupperware/System/Ftp/Incoming/Archive
FTP_INCOMING_DIR
/mnt/data/qc/Projects/Tupperware/System/Ftp/Incoming
FTP_OUTGOING_ARCHIVE_DIR
/mnt/data/qc/Projects/Tupperware/System/Ftp/OutGoing/Archive
FTP_OUTGOING_DIR
/mnt/data/qc/Projects/Tupperware/System/Ftp/OutGoing
HOME /Users/wlw
JAVA_ARCH x86_64
JAVA_MAIN_CLASS_2466 WaveMgr.WaveMgr
JDK /usr
JVER 1.6
LANG en_US.UTF-8
LD_LIBRARY_PATH
/mnt/data/qc/Sandboxes/wlw/Projects/Tupperware/Obj/MacOS/Lib:/mnt/data/qc/Projects/Tupperware/Obj/MacOS/Lib:/mnt/data/qc/Sandboxes/wlw/Develop/Obj/MacOS/Lib:/mnt/data/qc/Sandboxes/wlw/Products/Obj/MacOS/Lib:/mnt/data/qc/Sandboxes/wlw/Projects/Tupperware/Obj/MacOS/Lib:/mnt/data/qc/Projects/Tupperware/Obj/MacOS/Lib:/mnt/data/qc/Sandboxes/wlw/Develop/Obj/MacOS/Lib:/mnt/data/qc/Sandboxes/wlw/Products/Obj/MacOS/Lib::/mnt/data/qc/Sandboxes/wlw/Develop/Obj/MacOS/Lib:/mnt/data/qc/Sandboxes/wlw/Products/Obj/MacOS/Lib:/Applications/SQLAnywhere10/System/lib32::/mnt/data/qc/Sandboxes/wlw/Develop/Obj/MacOS/Lib:/mnt/data/qc/Sandboxes/wlw/Products/Obj/MacOS/Lib
LOGNAME wlw
LOG_DIR /mnt/data/qc/Projects/Tupperware/System/Log
MANPATH
/usr/share/man:/usr/local/share/man:/usr/X11/man
ODBCINI /Library/ODBC/odbc.ini
OLDPWD /Users/wlw
PATH
/mnt/data/qc/Sandboxes/wlw/Projects/Tupperware/Obj/MacOS/Bin:/mnt/data/qc/Projects/Tupperware/Bin:/mnt/data/qc/Projects/Tupperware/Obj/MacOS/Bin:/mnt/data/qc/Projects/Tupperware/System/Bin:/mnt/data/qc/Sandboxes/wlw/Develop/Obj/MacOS/Bin:/mnt/data/qc/Sandboxes/wlw/Products/Obj/MacOS/Bin:/mnt/data/qc/Sandboxes/wlw/Projects/Tupperware/Obj/MacOS/Bin:/mnt/data/qc/Projects/Tupperware/Bin:/mnt/data/qc/Projects/Tupperware/Obj/MacOS/Bin:/mnt/data/qc/Projects/Tupperware/System/Bin:/mnt/data/qc/Sandboxes/wlw/Develop/Obj/MacOS/Bin:/mnt/data/qc/Sandboxes/wlw/Products/Obj/MacOS/Bin:/Applications/SQLAnywhere10/System/bin32:/Applications/SQLAnywhere10/System/jre150/bin:/Applications/SQLAnywhere10/System/sybcentral500:/Applications/SQLAnywhere10/System/sybcentral500:/Applications/SQLAnywhere10/System/bin32:/bin:/usr/bin:/sbin:/usr/sbin:/usr/X11R6/bin:/usr/libexec/binutils::/usr/local/bin:/usr/X11/bin:/mnt/data/qc/Bin/MacOS:/Users/wlw/jswat-3.16/bin:/usr/jre/bin:/mnt/data/qc/Sandboxes/wlw/Dev
elop/Obj/MacOS/Bin:/mnt/data/qc/Sandboxes/wlw/Products/Obj/MacOS/Bin:/usr/jre/bin:/mnt/data/qc/Sandboxes/wlw/Develop/Obj/MacOS/Bin:/mnt/data/qc/Sandboxes/wlw/Products/Obj/MacOS/Bin
PRODUCTS /mnt/data/qc/Sandboxes/wlw/Products
PROJECTS /mnt/data/qc/Sandboxes/wlw/Projects
PROJECT_BASE /mnt/data/qc/Projects/Tupperware/System
PROJECT_NAME Tupperware
PWD
/mnt/data/qc/Sandboxes/wlw/Projects/Tupperware/Db
QCBASE /mnt/data/qc
QCCS_DB_ENGINE asa800
QCCS_DB_NAME Tupperware
SADIAGDIR /var/root/.sqlanywhere10/diagnostics
SANDBOX /mnt/data/qc/Sandboxes/wlw
SANDBOXES /mnt/data/qc/Sandboxes
SA_DYLD_LIBRARY_PATH /Applications/SQLAnywhere10/System/lib32:
SCRIPT_DIR
/mnt/data/qc/Projects/Tupperware/System/Scripts
SECURITYSESSIONID c534270
SECURITY_DIR
/mnt/data/qc/Projects/Tupperware/System/Security
SHELL /bin/bash
SHLVL 1
SQLANY10 /Applications/SQLAnywhere10/System
SQLANYSH10 /Applications/SQLAnywhere10/System
SSH_AUTH_SOCK /tmp/launch-syCeZc/Listeners
SYSLOG_DIR
/mnt/data/qc/Projects/Tupperware/System/Log/System
TCPIP_PORT_CTRL_NODE marina
TCPIP_PORT_CTRL_PORT 30000
TERM xterm-color
TERM_PROGRAM Apple_Terminal
TERM_PROGRAM_VERSION 240
TMPDIR
/var/folders/uf/ufN2L+BTEp00Q1lHHu+0dE+++TE/-Tmp-/
TMPLOG_DIR
/mnt/data/qc/Projects/Tupperware/System/Log/Tmp
TMP_DIR /mnt/data/qc/Projects/Tupperware/System/Tmp
TRACER_DIR
/mnt/data/qc/Projects/Tupperware/System/Log/Tmp
USER wlw
_ /usr/bin/java
__CF_USER_TEXT_ENCODING 0x1F4:0:0

Ray Ruvinskiy [Sybase iAnywhere]

unread,
Apr 3, 2009, 4:40:53 PM4/3/09
to
Hi Bill,

Java 1.6 on Mac OS X is 64-bit only and can only load 64-bit dylibs. We
did not provide 64-bit client libraries on Mac OS prior to the recently
released 11.0.1. In version 10, Interactive SQL and Sybase Central used
Java 1.5, which was 32-bit, and could load our dylibs.

As of version 11.0.1, we provide 64-bit dylibs that can be used with
Java 1.6. (And, in fact, our Admin Tools use Java 1.6 in version 11, as
well).

Bill Williams

unread,
Apr 3, 2009, 6:12:23 PM4/3/09
to
Thanks for the info.

Ray Ruvinskiy [Sybase iAnywhere] wrote:
> Hi Bill,
>

0 new messages