Reply
Expert Contributor
Posts: 263
Registered: ‎01-25-2017

Re: Impala queries through impala JDBC is running with empty user

Already tried this, I don't know how some can run query without user.

 

When i'm looking at CM i see akot of queries running with empty user and cann't localize the queries source and user, which make me hesitate to stop impala at my production cluster.

Expert Contributor
Posts: 263
Registered: ‎01-25-2017

Re: Impala queries through impala JDBC is running with empty user

Anyone here who is familiar with apache zeppelin?

Expert Contributor
Posts: 263
Registered: ‎01-25-2017

Re: Impala queries through impala JDBC is running with empty user

Any help?

Cloudera Employee
Posts: 73
Registered: ‎12-07-2015

Re: Impala queries through impala JDBC is running with empty user

Hi Fawze,

 

what version of the Impala JDBC driver are you using? What did you already try? The documentation of the latest version of the JDBC driver does not mention a "SID" parameter, but your connection string does. However, the documentation describes a "UID" parameter. Can you try using that one instead?

 

Cheers, Lars

Expert Contributor
Posts: 263
Registered: ‎01-25-2017

Re: Impala queries through impala JDBC is running with empty user

Hi Lars,

 

In your comments before you asked me to check the UID and i mentioned the version 'm using, unfortunately, it doesn't work.

Cloudera Employee
Posts: 73
Registered: ‎12-07-2015

Re: Impala queries through impala JDBC is running with empty user

Hi Fawze,

 

That version should have been downloaded from Cloudera and as such the downloaded file comes with its own version number. The current version is 2.5.36. "ImpalaJDBC4.jar" is the name of the file, not the version.

 

What is the connection string you used? What was the error you received?

 

Thanks, Lars

Expert Contributor
Posts: 263
Registered: ‎01-25-2017

Re: Impala queries through impala JDBC is running with empty user

[ Edited ]

jdbc:impala://ropr-dhc001:21050/;UID=fawze

 

Cloudera_ImpalaJDBC_2.5.5.1007.zip

 

No erros but the queries are running without user.

Cloudera Employee
Posts: 73
Registered: ‎12-07-2015

Re: Impala queries through impala JDBC is running with empty user

Your version of the driver seems to be 2.5.5. The current version is 2.5.36 and can be found here: http://www.cloudera.com/downloads/connectors/impala/jdbc/2-5-36.html

 

Please try again with the latest version and see if that help. The UID parameter should be supported there.

New Contributor
Posts: 1
Registered: ‎11-14-2017

Re: Impala queries through impala JDBC is running with empty user

Using Cloudera JDBC41_2.5.38.

Tried various combinations but no luck using JDBC, user is empty.

DataSource ds = new com.cloudera.impala.jdbc41.DataSource();
ds.setURL("jdbc:impala://<host>:21050;UseSasl=0;UID=test;AuthMech=0");
ds.setUserID("test");
ds.setLoginTimeout(60);
ds.setCustomProperty("UID", "test");
ds.setCustomProperty("USER", "test");
ds.setLogLevel(LogLevel.TRACE.toString());
ds.setLogDirectory("C:\\temp\\impala_log");
String sql = "select ....";

try (Connection connection = ds.getConnection(); ResultSet rs = connection.createStatement().executeQuery(sql) {

// print

We do not have authentication turned on so I do get result back but "user" is empty on impalad host http://<impaladhost>:25000/queries
25000/queries



I see that in python -> impala/hiveserver2.py it tries to read from os environment variable ('USER', 'USERNAME') etc.
I tried to do TRACE log for cloudera but could not make much sense of logs.

If I use hue from cloudera manager then I do see user in impalad.

Any idea what can I do in Java JDBC without turning on User or User/Password authentication.
 
Announcements