我是第一次使用NetSuite ODBC,但很难连接到它。我已经安装了驱动程序,但是当我尝试连接时,这是我得到的:
SQLDriverConnect: {01000} [unixODBC][Driver Manager]Can't open lib '/opt/netsuite/odbcclient/lib64/ivoa25.so' : file not found
如果我执行ldd /opt/netsuite/odbcclient/lib64/ivoa25.so
,这就是我得到的:
linux-vdso.so.1 => (0x00007ffd9f94d000)
librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007fbefbdb0000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007fbefbbac000)
libicuuc.so.42 => not found
libicudata.so.42 => not found
libpam.so.0 => /lib/x86_64-linux-gnu/libpam.so.0 (0x00007fbefb99e000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007fbefb781000)
libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007fbefb3f5000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fbefb0ec000)
libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007fbefaed4000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fbefab0a000)
/lib64/ld-linux-x86-64.so.2 (0x00007fbefc35e000)
libaudit.so.1 => /lib/x86_64-linux-gnu/libaudit.so.1 (0x00007fbefa8e3000)
not found
目录中存在这两个标记为/opt/netsuite/odbcclient/lib64
的文件,我不确定为什么将它们标记为not found
。
odbcinst -j
unixODBC 2.3.1
DRIVERS............: /etc/odbcinst.ini
SYSTEM DATA SOURCES: /etc/odbc.ini
FILE DATA SOURCES..: /etc/ODBCDataSources
USER DATA SOURCES..: /home/alen/.odbc.ini
SQLULEN Size.......: 8
SQLLEN Size........: 8
SQLSETPOSIROW Size.: 8
cat /etc/odbc.ini
[ODBC Data Sources]
NetSuite=NetSuite ODBC Drivers 7.2
[NetSuite]
Driver=/opt/netsuite/odbcclient/lib64/ivoa25.so
Description=Connect to your NetSuite account
Host=####
Port=####
ServerDataSource=######
Encrypted=1
Truststore=/opt/netsuite/odbcclient/cert/ca.cer, /opt/netsuite/odbcclient/cert/ca2.cer, /opt/netsuite/odbcclient/cert/ca3.cer
CustomProperties=AccountID=####;RoleID=####
[ODBC]
Trace=0
IANAAppCodePage=4
TraceFile=odbctrace.out
TraceDll=/opt/netsuite/odbcclient/lib64/ddtrc25.so
InstallDir=/opt/netsuite/odbcclient
答案 0 :(得分:0)
我有同样的问题。设置环境变量LD_LIBRARY_PATH
可以解决问题。如果您将Netsuite提取的文件放入/opt/netsuite/odbcclient
export LD_LIBRARY_PATH="/opt/netsuite/odbcclient/lib64${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}"
此外,请考虑netsuite驱动程序与Ubuntu 12.04兼容,因此它可能会有其他问题。