Kerberos impersonation for Hive (Beeline) -


i trying impersonate kerberos in order connect hive giving gss init exception.

usergroupinformation ugi = kinit.generatekerberosticket(configresources, keytab, principal); sergroupinformation ugiproxy =  usergroupinformation.createproxyuser("shashi", ugi.getcurrentuser());  ugiproxy.doas( new privilegedexceptionaction<void>(){             @override             public void run() throws exception {                 connection con = drivermanager.getconnection("jdbc:hive2://quickstart.cloudera:10000/default;principal=hive/quickstart.cloudera@cloudera", "shashi", "");                 statement stmt = con.createstatement();                 string sql = "show databases ";                 resultset res = stmt.executequery(sql);                 if (res.next()) {                     system.out.println("db names ---- >" +res.getstring(1));                 }                  makehivejdbcconnection();                 return null;             } 

but getting following exception .

java.sql.sqlexception: not open client transport jdbc uri: jdbc:hive2://quickstart.cloudera:10000/default;principal=hive/quickstart.cloudera@cloudera: gss initiate failed 

any clue issue?

unset hadoop proxy user first, beeline fail if not unset first


Comments

Popular posts from this blog

asynchronous - C# WinSCP .NET assembly: How to upload multiple files asynchronously -

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -