Created 07-22-2018 06:37 AM
I am not able to connect beeline from user tom but I am able to connect from hive .
Hive :
!connect jdbc:hive2://noescape.c.test:10000/default;principal=hive/[email protected]
here i am connected from hive
but when I go form tom it is not getting connected .
!connect jdbc:hive2://noescape.c.test:10000/default;[email protected]
Kerberos principal should have 3 parts: [email protected]
I tried different way also but no luck :
from root I did kinit tom
then beeline and !connect jdbc:hive2://noescape.c.test:10000/default it prompted for username and password , username tom and provided same password which i did while executing kinit tom . but this way below error :
Could not open client transport with JDBC Uri: jdbc:hive2://<host>:10000/default;: Peer indicated failure: Unsupported mechanism type PLAIN (state=08S01,code=0)
Created 07-23-2018 05:21 AM
@Anurag Mishra While logging in a Kerberized environment, you need to pass service principal name, in this case, hiveserver2 service principal name as part of JDBC connect string
eg:- principal=hive/_HOST@REALM
You can do a knit and then login using beeline with connect string as below
!connect jdbc:hive2://noescape.c.test:10000/default;principal=hive/[email protected]
Note: _HOST will be replaced as Hiveserver2 hostname
and the ticket will be picked from your local ticket cache. You may be prompted for username and password which can be ignored, press enter key twice.
Also you can try using below url if you do not wish to be prompted for username and password
beeline -u "jdbc:hive2://noescape.c.test:10000/default;principal=hive/[email protected]"
For more info on JDBC Sample connect string, please refer below HCC article and Apache documents:
Ref: https://community.hortonworks.com/articles/4103/hiveserver2-jdbc-connection-url-examples.html
Created 07-23-2018 05:21 AM
@Anurag Mishra While logging in a Kerberized environment, you need to pass service principal name, in this case, hiveserver2 service principal name as part of JDBC connect string
eg:- principal=hive/_HOST@REALM
You can do a knit and then login using beeline with connect string as below
!connect jdbc:hive2://noescape.c.test:10000/default;principal=hive/[email protected]
Note: _HOST will be replaced as Hiveserver2 hostname
and the ticket will be picked from your local ticket cache. You may be prompted for username and password which can be ignored, press enter key twice.
Also you can try using below url if you do not wish to be prompted for username and password
beeline -u "jdbc:hive2://noescape.c.test:10000/default;principal=hive/[email protected]"
For more info on JDBC Sample connect string, please refer below HCC article and Apache documents:
Ref: https://community.hortonworks.com/articles/4103/hiveserver2-jdbc-connection-url-examples.html
Created 07-23-2018 06:21 PM