You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kylin.apache.org by Marek Wiewiorka <ma...@gmail.com> on 2015/03/16 15:13:42 UTC

jdbc authentication failed

Hi All - no matter what cobination of user/pass I provide while
establishing jdbc connection
I always get the following exception:

java.util.concurrent.ExecutionException: java.lang.RuntimeException:
java.sql.SQLException: Authentication Failed.

My connection string is as follows:
jdbc:kylin://172.17.0.5:7070/default

I tried admin/KYLIN as credentials (also upper/lowercase).
kylin version:0.7.1-SNAPSHOT

I also tried to enable external LDAP authentication but I think it doesn't
seem to work at all.

Could please advise me what to do in such a case?n
Do I need external authentication to get it working - if so could please
tell me what
is the correct procedure of doing that?

Thanks
Marek

Re: jdbc authentication failed

Posted by Marek Wiewiorka <ma...@gmail.com>.
Ok - many. many thanks I will give a try!

Regards,
Marek

2015-03-17 9:22 GMT+01:00 Shi, Shaofeng <sh...@ebay.com>:

> We don¹t have a sample config for LDAP, as the search pattern differs by
> LDAPs; You may need contact your LDAP Admin to get some detail;
>
> For the ³ldap.service.*² settings, you can ignore I think; We leave it
> there because in our deployment we need authenticate service accounts (for
> system integrations); In our LDAP the service accounts are in a different
> directory so we need add it; In most of the scenarios, just configure
> ³ldap.user.*² is good enough;
>
> After switch to LDAP, you may need configure group for Kylin admins in
> LDAP, and then update the ³acl.adminRole² accordingly in kylin.properties,
> for example:
> acl.adminRole=ROLE_KYLIN-ADMIN
> acl.defaultRole=ROLE_ANALYST,ROLE_MODELER
>
>
> These configurations are parsed in kylniSecurity.xml, you can get started
> from it:
> https://github.com/KylinOLAP/Kylin/blob/master/server/src/main/resources/ky
> linSecurity.xml#L72
>
>
>
> On 3/17/15, 3:30 PM, "Marek Wiewiorka" <ma...@gmail.com> wrote:
>
> >ldap.user.groupSearchBase
>
>

Re: jdbc authentication failed

Posted by "Shi, Shaofeng" <sh...@ebay.com>.
We don¹t have a sample config for LDAP, as the search pattern differs by
LDAPs; You may need contact your LDAP Admin to get some detail;

For the ³ldap.service.*² settings, you can ignore I think; We leave it
there because in our deployment we need authenticate service accounts (for
system integrations); In our LDAP the service accounts are in a different
directory so we need add it; In most of the scenarios, just configure
³ldap.user.*² is good enough;

After switch to LDAP, you may need configure group for Kylin admins in
LDAP, and then update the ³acl.adminRole² accordingly in kylin.properties,
for example:
acl.adminRole=ROLE_KYLIN-ADMIN
acl.defaultRole=ROLE_ANALYST,ROLE_MODELER


These configurations are parsed in kylniSecurity.xml, you can get started
from it:
https://github.com/KylinOLAP/Kylin/blob/master/server/src/main/resources/ky
linSecurity.xml#L72



On 3/17/15, 3:30 PM, "Marek Wiewiorka" <ma...@gmail.com> wrote:

>ldap.user.groupSearchBase


Re: jdbc authentication failed

Posted by Marek Wiewiorka <ma...@gmail.com>.
Thanks a lot!!!
I specified the project name wrongly and this was causing the exception.
Everything is working fine now.
Could you please also share me a sample ldap configuration to make Kylin
support multiple users?
So far I have come up with something like this:

ldap.server=172.17.0.38:389
ldap.username=admin
ldap.password=admin123
ldap.user.searchBase='dc=example,dc=com'

#is this correct?
ldap.user.searchPattern='uid='
ldap.user.groupSearchBase='dc=example,dc=com'

#ok I think I know what to put here
ldap.service.searchBase=OU=

#here I have no clue what to type in
ldap.service.searchPattern=
ldap.service.groupSearchBase=

Many thanks in advance!

Marek


2015-03-17 4:36 GMT+01:00 Shi, Shaofeng <sh...@ebay.com>:

> I was able to connect Kylin with Squirrel-SQL, and can get query results
> back; Attached screen shot is my alias setting; Please let us know if you
> still have problem;
>
> On 3/17/15, 11:00 AM, "Shi, Shaofeng" <sh...@ebay.com> wrote:
>
> >what’s your Kylin project’s name? If it is not “default”, you need specify
> >the exact project name in JDBC connection URL:
> >
> >jdbc:kylin://172.17.0.5:7070/<your_kylin_project_name>
> >
> >
> >I’m using eclipse as the JDBC client, and I'm able to connect to my Kylin
> >server;
> >
> >On 3/17/15, 10:43 AM, "Shi, Shaofeng" <sh...@ebay.com> wrote:
> >
> >>The kylin_jdbc.log is in the folder when you run JDBC; Anyway, I will
> >>have
> >>a try with Squirrel-SQL; Will get back to you if have any finding;
> >>
> >>On 3/17/15, 1:02 AM, "Marek Wiewiorka" <ma...@gmail.com>
> wrote:
> >>
> >>>Hi - could you please let know where I can find this log.
> >>>I can find 2 two of them:
> >>>./bin/kylin_jdbc.log
> >>>./sample_cube/data/kylin_jdbc.log
> >>>
> >>>but I don't think they contain anything relevant only lines like that:
> >>>[main]:[2015-03-16
> >>>09:43:56,275][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecat
> >>>i
> >>>o
> >>>n(Configuration.java:599)]
> >>>- Handling deprecation for hive.error.on.empty.partition
> >>>[main]:[2015-03-16
> >>>09:43:56,278][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecat
> >>>i
> >>>o
> >>>n(Configuration.java:599)]
> >>>- Handling deprecation for hive.cli.errors.ignore
> >>>[main]:[2015-03-16
> >>>09:43:56,363][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecat
> >>>i
> >>>o
> >>>n(Configuration.java:599)]
> >>>- Handling deprecation for hive.stats.ndv.error
> >>>
> >>>I'm not sure if this is important but I try to setup a connection to
> >>>Kylin
> >>>using Squirrel-SQL.
> >>>It works perfectly fine using Web UI - I've got no problem with logging.
> >>>
> >>>Regards,
> >>>Marek
> >>>
> >>>
> >>>2015-03-16 15:45 GMT+01:00 Shi, Shaofeng <sh...@ebay.com>:
> >>>
> >>>> Hi Marek,
> >>>>
> >>>> Did you check the jdbc log file (kylin_jdbc.log)? Before throws the
> >>>> Authentication failed error, there should be some message be output to
> >>>>the
> >>>> log file, like:
> >>>>
> >>>> Authentication Failed with error code xxx and message: xxxxxx
> >>>>
> >>>> Please attache the full log file here is possible, I¹d like to check
> >>>> what¹s wrong in it.
> >>>>
> >>>> On 3/16/15, 10:13 PM, "Marek Wiewiorka" <ma...@gmail.com>
> >>>>wrote:
> >>>>
> >>>> >Hi All - no matter what cobination of user/pass I provide while
> >>>> >establishing jdbc connection
> >>>> >I always get the following exception:
> >>>> >
> >>>> >java.util.concurrent.ExecutionException: java.lang.RuntimeException:
> >>>> >java.sql.SQLException: Authentication Failed.
> >>>> >
> >>>> >My connection string is as follows:
> >>>> >jdbc:kylin://172.17.0.5:7070/default
> >>>> >
> >>>> >I tried admin/KYLIN as credentials (also upper/lowercase).
> >>>> >kylin version:0.7.1-SNAPSHOT
> >>>> >
> >>>> >I also tried to enable external LDAP authentication but I think it
> >>>>doesn't
> >>>> >seem to work at all.
> >>>> >
> >>>> >Could please advise me what to do in such a case?n
> >>>> >Do I need external authentication to get it working - if so could
> >>>>please
> >>>> >tell me what
> >>>> >is the correct procedure of doing that?
> >>>> >
> >>>> >Thanks
> >>>> >Marek
> >>>>
> >>>>
> >>
> >
>
>

Re: jdbc authentication failed

Posted by "Shi, Shaofeng" <sh...@ebay.com>.
I was able to connect Kylin with Squirrel-SQL, and can get query results
back; Attached screen shot is my alias setting; Please let us know if you
still have problem;

On 3/17/15, 11:00 AM, "Shi, Shaofeng" <sh...@ebay.com> wrote:

>what’s your Kylin project’s name? If it is not “default”, you need specify
>the exact project name in JDBC connection URL:
>
>jdbc:kylin://172.17.0.5:7070/<your_kylin_project_name>
>
>
>I’m using eclipse as the JDBC client, and I'm able to connect to my Kylin
>server;
>
>On 3/17/15, 10:43 AM, "Shi, Shaofeng" <sh...@ebay.com> wrote:
>
>>The kylin_jdbc.log is in the folder when you run JDBC; Anyway, I will
>>have
>>a try with Squirrel-SQL; Will get back to you if have any finding;
>>
>>On 3/17/15, 1:02 AM, "Marek Wiewiorka" <ma...@gmail.com> wrote:
>>
>>>Hi - could you please let know where I can find this log.
>>>I can find 2 two of them:
>>>./bin/kylin_jdbc.log
>>>./sample_cube/data/kylin_jdbc.log
>>>
>>>but I don't think they contain anything relevant only lines like that:
>>>[main]:[2015-03-16
>>>09:43:56,275][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecat
>>>i
>>>o
>>>n(Configuration.java:599)]
>>>- Handling deprecation for hive.error.on.empty.partition
>>>[main]:[2015-03-16
>>>09:43:56,278][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecat
>>>i
>>>o
>>>n(Configuration.java:599)]
>>>- Handling deprecation for hive.cli.errors.ignore
>>>[main]:[2015-03-16
>>>09:43:56,363][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecat
>>>i
>>>o
>>>n(Configuration.java:599)]
>>>- Handling deprecation for hive.stats.ndv.error
>>>
>>>I'm not sure if this is important but I try to setup a connection to
>>>Kylin
>>>using Squirrel-SQL.
>>>It works perfectly fine using Web UI - I've got no problem with logging.
>>>
>>>Regards,
>>>Marek
>>>
>>>
>>>2015-03-16 15:45 GMT+01:00 Shi, Shaofeng <sh...@ebay.com>:
>>>
>>>> Hi Marek,
>>>>
>>>> Did you check the jdbc log file (kylin_jdbc.log)? Before throws the
>>>> Authentication failed error, there should be some message be output to
>>>>the
>>>> log file, like:
>>>>
>>>> Authentication Failed with error code xxx and message: xxxxxx
>>>>
>>>> Please attache the full log file here is possible, I¹d like to check
>>>> what¹s wrong in it.
>>>>
>>>> On 3/16/15, 10:13 PM, "Marek Wiewiorka" <ma...@gmail.com>
>>>>wrote:
>>>>
>>>> >Hi All - no matter what cobination of user/pass I provide while
>>>> >establishing jdbc connection
>>>> >I always get the following exception:
>>>> >
>>>> >java.util.concurrent.ExecutionException: java.lang.RuntimeException:
>>>> >java.sql.SQLException: Authentication Failed.
>>>> >
>>>> >My connection string is as follows:
>>>> >jdbc:kylin://172.17.0.5:7070/default
>>>> >
>>>> >I tried admin/KYLIN as credentials (also upper/lowercase).
>>>> >kylin version:0.7.1-SNAPSHOT
>>>> >
>>>> >I also tried to enable external LDAP authentication but I think it
>>>>doesn't
>>>> >seem to work at all.
>>>> >
>>>> >Could please advise me what to do in such a case?n
>>>> >Do I need external authentication to get it working - if so could
>>>>please
>>>> >tell me what
>>>> >is the correct procedure of doing that?
>>>> >
>>>> >Thanks
>>>> >Marek
>>>>
>>>>
>>
>


Re: jdbc authentication failed

Posted by "Shi, Shaofeng" <sh...@ebay.com>.
what’s your Kylin project’s name? If it is not “default”, you need specify
the exact project name in JDBC connection URL:

jdbc:kylin://172.17.0.5:7070/<your_kylin_project_name>


I’m using eclipse as the JDBC client, and I'm able to connect to my Kylin
server;

On 3/17/15, 10:43 AM, "Shi, Shaofeng" <sh...@ebay.com> wrote:

>The kylin_jdbc.log is in the folder when you run JDBC; Anyway, I will have
>a try with Squirrel-SQL; Will get back to you if have any finding;
>
>On 3/17/15, 1:02 AM, "Marek Wiewiorka" <ma...@gmail.com> wrote:
>
>>Hi - could you please let know where I can find this log.
>>I can find 2 two of them:
>>./bin/kylin_jdbc.log
>>./sample_cube/data/kylin_jdbc.log
>>
>>but I don't think they contain anything relevant only lines like that:
>>[main]:[2015-03-16
>>09:43:56,275][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecati
>>o
>>n(Configuration.java:599)]
>>- Handling deprecation for hive.error.on.empty.partition
>>[main]:[2015-03-16
>>09:43:56,278][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecati
>>o
>>n(Configuration.java:599)]
>>- Handling deprecation for hive.cli.errors.ignore
>>[main]:[2015-03-16
>>09:43:56,363][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecati
>>o
>>n(Configuration.java:599)]
>>- Handling deprecation for hive.stats.ndv.error
>>
>>I'm not sure if this is important but I try to setup a connection to
>>Kylin
>>using Squirrel-SQL.
>>It works perfectly fine using Web UI - I've got no problem with logging.
>>
>>Regards,
>>Marek
>>
>>
>>2015-03-16 15:45 GMT+01:00 Shi, Shaofeng <sh...@ebay.com>:
>>
>>> Hi Marek,
>>>
>>> Did you check the jdbc log file (kylin_jdbc.log)? Before throws the
>>> Authentication failed error, there should be some message be output to
>>>the
>>> log file, like:
>>>
>>> Authentication Failed with error code xxx and message: xxxxxx
>>>
>>> Please attache the full log file here is possible, I¹d like to check
>>> what¹s wrong in it.
>>>
>>> On 3/16/15, 10:13 PM, "Marek Wiewiorka" <ma...@gmail.com>
>>>wrote:
>>>
>>> >Hi All - no matter what cobination of user/pass I provide while
>>> >establishing jdbc connection
>>> >I always get the following exception:
>>> >
>>> >java.util.concurrent.ExecutionException: java.lang.RuntimeException:
>>> >java.sql.SQLException: Authentication Failed.
>>> >
>>> >My connection string is as follows:
>>> >jdbc:kylin://172.17.0.5:7070/default
>>> >
>>> >I tried admin/KYLIN as credentials (also upper/lowercase).
>>> >kylin version:0.7.1-SNAPSHOT
>>> >
>>> >I also tried to enable external LDAP authentication but I think it
>>>doesn't
>>> >seem to work at all.
>>> >
>>> >Could please advise me what to do in such a case?n
>>> >Do I need external authentication to get it working - if so could
>>>please
>>> >tell me what
>>> >is the correct procedure of doing that?
>>> >
>>> >Thanks
>>> >Marek
>>>
>>>
>


Re: jdbc authentication failed

Posted by "Shi, Shaofeng" <sh...@ebay.com>.
The kylin_jdbc.log is in the folder when you run JDBC; Anyway, I will have
a try with Squirrel-SQL; Will get back to you if have any finding;

On 3/17/15, 1:02 AM, "Marek Wiewiorka" <ma...@gmail.com> wrote:

>Hi - could you please let know where I can find this log.
>I can find 2 two of them:
>./bin/kylin_jdbc.log
>./sample_cube/data/kylin_jdbc.log
>
>but I don't think they contain anything relevant only lines like that:
>[main]:[2015-03-16
>09:43:56,275][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecatio
>n(Configuration.java:599)]
>- Handling deprecation for hive.error.on.empty.partition
>[main]:[2015-03-16
>09:43:56,278][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecatio
>n(Configuration.java:599)]
>- Handling deprecation for hive.cli.errors.ignore
>[main]:[2015-03-16
>09:43:56,363][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecatio
>n(Configuration.java:599)]
>- Handling deprecation for hive.stats.ndv.error
>
>I'm not sure if this is important but I try to setup a connection to Kylin
>using Squirrel-SQL.
>It works perfectly fine using Web UI - I've got no problem with logging.
>
>Regards,
>Marek
>
>
>2015-03-16 15:45 GMT+01:00 Shi, Shaofeng <sh...@ebay.com>:
>
>> Hi Marek,
>>
>> Did you check the jdbc log file (kylin_jdbc.log)? Before throws the
>> Authentication failed error, there should be some message be output to
>>the
>> log file, like:
>>
>> Authentication Failed with error code xxx and message: xxxxxx
>>
>> Please attache the full log file here is possible, I¹d like to check
>> what¹s wrong in it.
>>
>> On 3/16/15, 10:13 PM, "Marek Wiewiorka" <ma...@gmail.com>
>>wrote:
>>
>> >Hi All - no matter what cobination of user/pass I provide while
>> >establishing jdbc connection
>> >I always get the following exception:
>> >
>> >java.util.concurrent.ExecutionException: java.lang.RuntimeException:
>> >java.sql.SQLException: Authentication Failed.
>> >
>> >My connection string is as follows:
>> >jdbc:kylin://172.17.0.5:7070/default
>> >
>> >I tried admin/KYLIN as credentials (also upper/lowercase).
>> >kylin version:0.7.1-SNAPSHOT
>> >
>> >I also tried to enable external LDAP authentication but I think it
>>doesn't
>> >seem to work at all.
>> >
>> >Could please advise me what to do in such a case?n
>> >Do I need external authentication to get it working - if so could
>>please
>> >tell me what
>> >is the correct procedure of doing that?
>> >
>> >Thanks
>> >Marek
>>
>>


Re: jdbc authentication failed

Posted by Marek Wiewiorka <ma...@gmail.com>.
Hi - could you please let know where I can find this log.
I can find 2 two of them:
./bin/kylin_jdbc.log
./sample_cube/data/kylin_jdbc.log

but I don't think they contain anything relevant only lines like that:
[main]:[2015-03-16
09:43:56,275][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecation(Configuration.java:599)]
- Handling deprecation for hive.error.on.empty.partition
[main]:[2015-03-16
09:43:56,278][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecation(Configuration.java:599)]
- Handling deprecation for hive.cli.errors.ignore
[main]:[2015-03-16
09:43:56,363][DEBUG][org.apache.hadoop.conf.Configuration.handleDeprecation(Configuration.java:599)]
- Handling deprecation for hive.stats.ndv.error

I'm not sure if this is important but I try to setup a connection to Kylin
using Squirrel-SQL.
It works perfectly fine using Web UI - I've got no problem with logging.

Regards,
Marek


2015-03-16 15:45 GMT+01:00 Shi, Shaofeng <sh...@ebay.com>:

> Hi Marek,
>
> Did you check the jdbc log file (kylin_jdbc.log)? Before throws the
> Authentication failed error, there should be some message be output to the
> log file, like:
>
> Authentication Failed with error code xxx and message: xxxxxx
>
> Please attache the full log file here is possible, I¹d like to check
> what¹s wrong in it.
>
> On 3/16/15, 10:13 PM, "Marek Wiewiorka" <ma...@gmail.com> wrote:
>
> >Hi All - no matter what cobination of user/pass I provide while
> >establishing jdbc connection
> >I always get the following exception:
> >
> >java.util.concurrent.ExecutionException: java.lang.RuntimeException:
> >java.sql.SQLException: Authentication Failed.
> >
> >My connection string is as follows:
> >jdbc:kylin://172.17.0.5:7070/default
> >
> >I tried admin/KYLIN as credentials (also upper/lowercase).
> >kylin version:0.7.1-SNAPSHOT
> >
> >I also tried to enable external LDAP authentication but I think it doesn't
> >seem to work at all.
> >
> >Could please advise me what to do in such a case?n
> >Do I need external authentication to get it working - if so could please
> >tell me what
> >is the correct procedure of doing that?
> >
> >Thanks
> >Marek
>
>

Re: jdbc authentication failed

Posted by "Shi, Shaofeng" <sh...@ebay.com>.
Hi Marek,

Did you check the jdbc log file (kylin_jdbc.log)? Before throws the
Authentication failed error, there should be some message be output to the
log file, like:

Authentication Failed with error code xxx and message: xxxxxx

Please attache the full log file here is possible, I¹d like to check
what¹s wrong in it.

On 3/16/15, 10:13 PM, "Marek Wiewiorka" <ma...@gmail.com> wrote:

>Hi All - no matter what cobination of user/pass I provide while
>establishing jdbc connection
>I always get the following exception:
>
>java.util.concurrent.ExecutionException: java.lang.RuntimeException:
>java.sql.SQLException: Authentication Failed.
>
>My connection string is as follows:
>jdbc:kylin://172.17.0.5:7070/default
>
>I tried admin/KYLIN as credentials (also upper/lowercase).
>kylin version:0.7.1-SNAPSHOT
>
>I also tried to enable external LDAP authentication but I think it doesn't
>seem to work at all.
>
>Could please advise me what to do in such a case?n
>Do I need external authentication to get it working - if so could please
>tell me what
>is the correct procedure of doing that?
>
>Thanks
>Marek