hive jdbc error while connect to AWS kerberos cluster

This is for Hadoop eco system like HDFS, Map reduce, Hive, Hbase, Pig, sqoop,sqoop2, Avro, solr, hcatalog, impala, Oozie, Zoo Keeper and Hadoop distribution like Cloudera, Hortonwork etc.
hadoopuser
Posts: 42
Joined: Mon Jul 21, 2014 7:40 pm
Contact:

hive jdbc error while connect to AWS kerberos cluster

Postby hadoopuser » Wed Jan 17, 2018 3:35 am

I am getting below error while connecting aws hive using jdbc

driver=org.apache.hive.jdbc.HiveDriver
port=10000
user=hive
pass=
url=jdbc:hive2://ip-10-237-187-82.aws-w-np.nielsencsp.net:10000

Code: Select all

ERROR StatusLogger No log4j2 configuration file found. Using default configuration: logging only errors to the console. Set system property 'org.apache.logging.log4j.simplelog.StatusLogger.level' to TRACE to show Log4j2 internal initialization logging.
Exception in thread "main" java.sql.SQLException: Could not open client transport with JDBC Uri: jdbc:hive2://localhost:10000/default: Peer indicated failure: Unsupported mechanism type PLAIN
   at org.apache.hive.jdbc.HiveConnection.openTransport(HiveConnection.java:215)
   at org.apache.hive.jdbc.HiveConnection.<init>(HiveConnection.java:163)
   at org.apache.hive.jdbc.HiveDriver.connect(HiveDriver.java:105)
   at java.sql.DriverManager.getConnection(DriverManager.java:571)
   at java.sql.DriverManager.getConnection(DriverManager.java:215)
   at main.java.com.carrieriq.dailymergetest.DailyMergeTest.runHiveJDBC(DailyMergeTest.java:218)
   at main.java.com.carrieriq.dailymergetest.DailyMergeTest.main(DailyMergeTest.java:245)
Caused by: org.apache.thrift.transport.TTransportException: Peer indicated failure: Unsupported mechanism type PLAIN
   at org.apache.thrift.transport.TSaslTransport.receiveSaslMessage(TSaslTransport.java:199)
   at org.apache.thrift.transport.TSaslTransport.open(TSaslTransport.java:307)
   at org.apache.thrift.transport.TSaslClientTransport.open(TSaslClientTransport.java:37)
   at org.apache.hive.jdbc.HiveConnection.openTransport(HiveConnection.java:190)
   ... 6 more


Guest

Re: hive jdbc error while connect to AWS kerberos cluster

Postby Guest » Wed Jan 17, 2018 3:46 am

change your url. I think for AWS you may have kerberos setup

url=jdbc:hive2://localhost:10000/default;principal=hive/localhost@HADOOP.COM

Guest

Re: hive jdbc error while connect to AWS kerberos cluster

Postby Guest » Wed Jan 17, 2018 4:38 am

Thanks by changing url I got javax.security.sasl.SaslException: GSS initiate failed. Error


ERROR StatusLogger No log4j2 configuration file found. Using default configuration: logging only errors to the console. Set system property 'org.apache.logging.log4j.simplelog.StatusLogger.level' to TRACE to show Log4j2 internal initialization logging.
19:43:08.218 [main] ERROR org.apache.thrift.transport.TSaslTransport - SASL negotiation failure
javax.security.sasl.SaslException: GSS initiate failed
at com.sun.security.sasl.gsskerb.GssKrb5Client.evaluateChallenge(GssKrb5Client.java:212) ~[?:1.7.0_79]
at org.apache.thrift.transport.TSaslClientTransport.handleSaslStartMessage(TSaslClientTransport.java:94) ~[libthrift-0.9.2.jar:0.9.2]
at org.apache.thrift.transport.TSaslTransport.open(TSaslTransport.java:271) [libthrift-0.9.2.jar:0.9.2]

hadoopuser
Posts: 42
Joined: Mon Jul 21, 2014 7:40 pm
Contact:

Re: hive jdbc error while connect to AWS kerberos cluster

Postby hadoopuser » Wed Jan 17, 2018 4:40 am

look at below link: it is related to krb5.conf file

viewtopic.php?f=2&t=258774



Return to “Hadoop and Big Data”

Who is online

Users browsing this forum: No registered users and 1 guest