Last active
August 29, 2015 14:17
-
-
Save gbraccialli/414c13b3ebace8e54350 to your computer and use it in GitHub Desktop.
unixODBC - troubleshooting
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1- check version unixODBC (> 2.3.0) | |
isql --version | |
2- check if both: unixODBC binary and your drive are 32bits or both are 64bits (different versions causes file not found error) | |
which isql | |
file /usr/local/unixODBC/bin/isql | |
file /usr/lib/hive/lib/native/Linux-amd64-64/libhortonworkshiveodbc64.so | |
3- check $LD_LIBRARY_PATH (/usr/local/unixODBC/bin/:/usr/lib/hive/lib/native/Linux-amd64-64/) | |
4- check any missing library | |
ldd /usr/lib/hive/lib/native/Linux-amd64-64/libhortonworkshiveodbc64.so | |
5- check hortonworks.hiveodbc.ini on your home directory or /etc/hortonworks.hiveodbc.ini | |
6- check DriverManagerEncoding=UTF-16 from hortonworks.hiveodbc.ini (see comments on hortonworks.hiveodbc.ini) | |
7- check ODBCInstLib=libodbcinst.so.1 (see comments on hortonworks.hiveodbc.ini, new unixODBC version comes with libodbcinst.so.2.0.0 instead of libodbcinst.so.1, change hortonworks.hiveodbc.ini or create link) | |
8- .odbc.ini sample: | |
[hive1] | |
Driver=/usr/lib/hive/lib/native/Linux-amd64-64/libhortonworkshiveodbc64.so | |
HOST=localhost | |
PORT=10000 | |
Schema=default | |
FastSQLPrepare=0 | |
UseNativeQuery=0 | |
HiveServerType=2 | |
AuthMech=2 | |
KrbHostFQDN=x | |
KrbServiceName=ax | |
UID=hive | |
PWD=xxx | |
9- (final resource): strace -s 1000 /usr/local/unixODBC/bin/isql -v hive1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment