Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

ImpalaJDBCDriver Error in setting uid and password: null Error with Impala JDBC Driver

ImpalaJDBCDriver Error in setting uid and password: null Error with Impala JDBC Driver

This took us a bit to figure out, so wanted to share in case anyone else runs into the issue.  It's probably documented someplace, but we ended up needing to dig through the ‘com.cloudera.impala.hivecommon.core.HiveJDBCConnection’ code to find it.

 

Using the document below, what we're trying to do is hook our application up via JDBC into Impala using LDAP authentication with SSL/TLS enabled.  Here was our original connection string.

 

jdbc:impala://<impalahost>:21050/;AllowSelfSignedCerts=true;AuthMech=4;SSLKeyStore=/keystores/clientkeystore;SSLKeyStorePwd=<password>;UID=<user>;PWD=<password>

 

This tossed us the error "[Simba][ImpalaJDBCDriver](500204) Error in setting uid and password: null "

 

We spent a while trying to figure out why our username and password were wrong without much luck.  So we ended up looking into the HiveJDBCConnection class and noticed that the exception was actually because we were passing in AllowSelfSignedCerts=true.  Turns out it's expecting AllowSelfSignedCerts=1 to turn this feature on.

 

We also found that the chart on the last few pages indicates '5' is the correct value for AuthMech when you are using LDAP (username and password) with SSL.   It's actually '4' as indicated earlier in the document in the examples.

 

Anyway, no action needed.  Just wanted to share and contribute back.

 

http://www.cloudera.com/content/www/en-us/documentation/other/connectors/impala-jdbc/2-5-5/Cloudera-...

Don't have an account?
Coming from Hortonworks? Activate your account here