<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: knox to hivserver2 call does not work on ssl cluster in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175602#M58228</link>
    <description>&lt;P&gt;actually either there was something wrong in my clsuter or I had not restarted the knox after adding hive cert to the knox trust cacert. because after i lost the clsuter and created the new cluster and after doing necessary steps it worked, accepting your answer because the problem you shared was real issue that i had faced earlier with webhdfs , and was seeing the such issue.&lt;/P&gt;</description>
    <pubDate>Thu, 30 Mar 2017 18:20:15 GMT</pubDate>
    <dc:creator>dsharma</dc:creator>
    <dc:date>2017-03-30T18:20:15Z</dc:date>
    <item>
      <title>knox to hivserver2 call does not work on ssl cluster</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175593#M58219</link>
      <description>&lt;P&gt;I am seeing issue when I configured knox to work with hive ssl , using the following doc.&lt;/P&gt;&lt;P&gt;&lt;A href="https://hortonworks.com/blog/end-end-wire-encryption-apache-knox/" target="_blank"&gt;https://hortonworks.com/blog/end-end-wire-encryption-apache-knox/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;I am trying to make following call :&lt;/P&gt;&lt;P&gt;beeline --silent=true -u "jdbc:hive2://&amp;lt;knox_host&amp;gt;:8443/;ssl=true;sslTrustStore=/usr/hdp/current/knox-server/data/security/keystores/gateway.jks;trustStorePassword=knoxsecret;transportMode=http;httpPath=gateway/default/hive;hive.server2.use.SSL=true" -d org.apache.hive.jdbc.HiveDriver -n sam -p sam-password &lt;/P&gt;&lt;PRE&gt;







17/03/27 13:01:12 [main]: ERROR jdbc.HiveConnection: Error opening session

org.apache.thrift.transport.TTransportException: HTTP Response code: 500

	at org.apache.thrift.transport.THttpClient.flushUsingHttpClient(THttpClient.java:262)

	at org.apache.thrift.transport.THttpClient.flush(THttpClient.java:313)

	at org.apache.thrift.TServiceClient.sendBase(TServiceClient.java:73)

	at org.apache.thrift.TServiceClient.sendBase(TServiceClient.java:62)

	at org.apache.hive.service.cli.thrift.TCLIService$Client.send_OpenSession(TCLIService.java:154)

	at org.apache.hive.service.cli.thrift.TCLIService$Client.OpenSession(TCLIService.java:146)

	at org.apache.hive.jdbc.HiveConnection.openSession(HiveConnection.java:553)

	at org.apache.hive.jdbc.HiveConnection.&amp;lt;init&amp;gt;(HiveConnection.java:171)

	at org.apache.hive.jdbc.HiveDriver.connect(HiveDriver.java:105)

	at java.sql.DriverManager.getConnection(DriverManager.java:664)

	at java.sql.DriverManager.getConnection(DriverManager.java:208)

	at org.apache.hive.beeline.DatabaseConnection.connect(DatabaseConnection.java:146)

	at org.apache.hive.beeline.DatabaseConnection.getConnection(DatabaseConnection.java:211)

	at org.apache.hive.beeline.Commands.close(Commands.java:1016)

	at org.apache.hive.beeline.Commands.closeall(Commands.java:998)

	at org.apache.hive.beeline.BeeLine.close(BeeLine.java:846)

	at org.apache.hive.beeline.BeeLine.begin(BeeLine.java:793)

	at org.apache.hive.beeline.BeeLine.mainWithInputRedirection(BeeLine.java:491)

	at org.apache.hive.beeline.BeeLine.main(BeeLine.java:474)

	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

	at java.lang.reflect.Method.invoke(Method.java:498)

	at org.apache.hadoop.util.RunJar.run(RunJar.java:233)

	at org.apache.hadoop.util.RunJar.main(RunJar.java:148)

&lt;/PRE&gt;&lt;P&gt;gateway-audit.log&lt;/P&gt;&lt;PRE&gt;17/03/27 13:01:12 ||1ebe2bff-8ed2-4c68-84fa-13166d10b73f|audit|HIVE||||access|uri|/gateway/default/hive|unavailable|Request method: POST17/03/27 13:01:12 ||1ebe2bff-8ed2-4c68-84fa-13166d10b73f|audit|HIVE|sam|||authentication|uri|/gateway/default/hive|success|17/03/27 13:01:12 ||1ebe2bff-8ed2-4c68-84fa-13166d10b73f|audit|HIVE|sam|||authentication|uri|/gateway/default/hive|success|Groups: []17/03/27 13:01:12 ||1ebe2bff-8ed2-4c68-84fa-13166d10b73f|audit|HIVE|sam|||dispatch|uri|https://&amp;lt;hiveserver&amp;gt;:10001/cliservice?doAs=sam|unavailable|Request method: POST17/03/27 13:01:12 ||1ebe2bff-8ed2-4c68-84fa-13166d10b73f|audit|HIVE|sam|||dispatch|uri|https://&amp;lt;hiveserver&amp;gt;:10001/cliservice?doAs=sam|failure|3&lt;/PRE&gt;&lt;P&gt;gateway.log&lt;/P&gt;&lt;PRE&gt;Caused by: org.apache.shiro.subject.ExecutionException: java.security.PrivilegedActionException: java.io.IOException: Service connectivity error.        at org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:385)        at org.apache.hadoop.gateway.filter.ShiroSubjectIdentityAdapter.doFilter(ShiroSubjectIdentityAdapter.java:72)        at org.apache.hadoop.gateway.GatewayFilter$Holder.doFilter(GatewayFilter.java:332)        at org.apache.hadoop.gateway.GatewayFilter$Chain.doFilter(GatewayFilter.java:232)        at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:61)        at org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108)        at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137)        ... 48 moreCaused by: java.security.PrivilegedActionException: java.io.IOException: Service connectivity error.        at java.security.AccessController.doPrivileged(Native Method)        at javax.security.auth.Subject.doAs(Subject.java:415)        at org.apache.hadoop.gateway.filter.ShiroSubjectIdentityAdapter$CallableChain.call(ShiroSubjectIdentityAdapter.java:138)        at org.apache.hadoop.gateway.filter.ShiroSubjectIdentityAdapter$CallableChain.call(ShiroSubjectIdentityAdapter.java:75)        at org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90)        at org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83)        at org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:383)        ... 54 moreCaused by: java.io.IOException: Service connectivity error.        at org.apache.hadoop.gateway.dispatch.DefaultDispatch.executeOutboundRequest(DefaultDispatch.java:147)        at org.apache.hadoop.gateway.dispatch.DefaultDispatch.executeRequest(DefaultDispatch.java:115)        at org.apache.hadoop.gateway.dispatch.DefaultDispatch.doPost(DefaultDispatch.java:304)        at org.apache.hadoop.gateway.dispatch.GatewayDispatchFilter$PostAdapter.doMethod(GatewayDispatchFilter.java:130)        at org.apache.hadoop.gateway.dispatch.GatewayDispatchFilter.doFilter(GatewayDispatchFilter.j&lt;/PRE&gt;&lt;P&gt;tried configuring both of the following topology(http/https), same operation was working before enabling ssl:&lt;/P&gt;&lt;P&gt;&amp;lt;service&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;role&amp;gt;HIVE&amp;lt;/role&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;url&amp;gt;https://&amp;lt;hive_host&amp;gt;:10001/cliservice&amp;lt;/url&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/service&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;service&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;role&amp;gt;HIVE&amp;lt;/role&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;url&amp;gt;http://&amp;lt;hive_host&amp;gt;:10001/cliservice&amp;lt;/url&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/service&amp;gt;&lt;/P&gt;</description>
      <pubDate>Mon, 27 Mar 2017 20:16:17 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175593#M58219</guid>
      <dc:creator>dsharma</dc:creator>
      <dc:date>2017-03-27T20:16:17Z</dc:date>
    </item>
    <item>
      <title>Re: knox to hivserver2 call does not work on ssl cluster</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175594#M58220</link>
      <description>&lt;P&gt;Hey &lt;A rel="user" href="https://community.cloudera.com/users/505/dsharma.html" nodeid="505"&gt;@Deepak Sharma&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;Looks like the connectivity between Knox server and HiveServer2 (HS2) is broken. So,&lt;/P&gt;&lt;P&gt;1. Have you checked that Beeline works fine without Knox &amp;amp; using HS2 (over SSL) directly?&lt;/P&gt;&lt;P&gt;2. Also after enabling SSL for Hive, you need to establish trust between Knox service and HS2 by importing their certificates into each other's truststore. Have you done this?&lt;/P&gt;&lt;P&gt;These two should definitely give you some breakthrough. Let us know !&lt;/P&gt;</description>
      <pubDate>Tue, 28 Mar 2017 00:39:15 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175594#M58220</guid>
      <dc:creator>VR46</dc:creator>
      <dc:date>2017-03-28T00:39:15Z</dc:date>
    </item>
    <item>
      <title>Re: knox to hivserver2 call does not work on ssl cluster</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175595#M58221</link>
      <description>&lt;P&gt;hey thanks &lt;A rel="user" href="https://community.cloudera.com/users/740/vrathor.html" nodeid="740"&gt;@Vipin Rathor&lt;/A&gt; for reply&lt;/P&gt;&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/740/vrathor.html" nodeid="740"&gt;&lt;/A&gt;&amp;gt;&amp;gt; 1. Have you checked that Beeline works fine without Knox &amp;amp; using HS2 (over SSL) directly &lt;/P&gt;&lt;P&gt;yes beeline works using HS2 over ssl&lt;/P&gt;&lt;P&gt;2. Also after enabling SSL for Hive, you need to establish trust between Knox service and HS2 by importing their certificates into each other's truststore. Have you done this?&lt;/P&gt;&lt;P&gt;&amp;gt;&amp;gt; I sense here one way ssl should be enough, assuming for hbase and webhdfs one way ssl works, i have not imported knox crt into hive truststore, so i guess behaviour  should be same here also&lt;/P&gt;</description>
      <pubDate>Tue, 28 Mar 2017 03:00:55 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175595#M58221</guid>
      <dc:creator>dsharma</dc:creator>
      <dc:date>2017-03-28T03:00:55Z</dc:date>
    </item>
    <item>
      <title>Re: knox to hivserver2 call does not work on ssl cluster</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175596#M58222</link>
      <description>&lt;P&gt;Hey, can you please try importing knox cert into hive truststore? That  will be a logical thing to try if one way is not working.&lt;/P&gt;</description>
      <pubDate>Tue, 28 Mar 2017 03:15:09 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175596#M58222</guid>
      <dc:creator>VR46</dc:creator>
      <dc:date>2017-03-28T03:15:09Z</dc:date>
    </item>
    <item>
      <title>Re: knox to hivserver2 call does not work on ssl cluster</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175597#M58223</link>
      <description>&lt;P&gt;1- check if hive.server2.use.SSL property is set to true on Hive front , 2- make sure the HS2 host certificate(that exists in /etc/security/serverKeys) is copied to cacerts on knox host 3- make sure the knox topology is referring to &lt;A href="https://&amp;lt;hiveserver2_host&amp;gt;:&amp;lt;port&amp;gt;" target="_blank"&gt;https://&amp;lt;hiveserver2_host&amp;gt;:&amp;lt;port&amp;gt;&lt;/A&gt;;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Mar 2017 04:01:08 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175597#M58223</guid>
      <dc:creator>skoneru</dc:creator>
      <dc:date>2017-03-28T04:01:08Z</dc:date>
    </item>
    <item>
      <title>Re: knox to hivserver2 call does not work on ssl cluster</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175598#M58224</link>
      <description>&lt;P&gt;yes surya it is set to true &lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="14109-screen-shot-2017-03-28-at-23646-am.png" style="width: 2062px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/19776iD1F2F2B3F64D171B/image-size/medium?v=v2&amp;amp;px=400" role="button" title="14109-screen-shot-2017-03-28-at-23646-am.png" alt="14109-screen-shot-2017-03-28-at-23646-am.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 18 Aug 2019 10:07:06 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175598#M58224</guid>
      <dc:creator>dsharma</dc:creator>
      <dc:date>2019-08-18T10:07:06Z</dc:date>
    </item>
    <item>
      <title>Re: knox to hivserver2 call does not work on ssl cluster</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175599#M58225</link>
      <description>&lt;P&gt;Vipin, tried configuring two way ssl also , it does not work, so strange part is :&lt;/P&gt;&lt;P&gt;1) the error i am getting does not seems relevant to wire encryption&lt;/P&gt;&lt;P&gt;2) but whenever i disable ssl for hive, knox to hive flow it start working &lt;/P&gt;</description>
      <pubDate>Tue, 28 Mar 2017 04:11:10 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175599#M58225</guid>
      <dc:creator>dsharma</dc:creator>
      <dc:date>2017-03-28T04:11:10Z</dc:date>
    </item>
    <item>
      <title>Re: knox to hivserver2 call does not work on ssl cluster</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175600#M58226</link>
      <description>&lt;P&gt;Hi &lt;A rel="user" href="https://community.cloudera.com/users/505/dsharma.html" nodeid="505"&gt;@Deepak Sharma&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;If you are using HDP version 2.5 there is a bug when using wire encryption with hive and trying to access with knox in a kerberized cluster.  See &lt;A href="https://issues.apache.org/jira/browse/KNOX-762" target="_blank"&gt;https://issues.apache.org/jira/browse/KNOX-762&lt;/A&gt;  .  You will see in the knox kerberos debug log that knox is trying to authenticate using spengo keytab with HTTPS instead of HTTP.  To resolve this issue downgrade the httpclient jar to httpclient-4.5.1.jar .on knox.  &lt;/P&gt;</description>
      <pubDate>Wed, 29 Mar 2017 01:42:51 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175600#M58226</guid>
      <dc:creator>dvillarreal</dc:creator>
      <dc:date>2017-03-29T01:42:51Z</dc:date>
    </item>
    <item>
      <title>Re: knox to hivserver2 call does not work on ssl cluster</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175601#M58227</link>
      <description>&lt;P&gt;&lt;A href="https://community.hortonworks.com/users/509/dvillarreal.html"&gt;dvillarreal&lt;/A&gt; thanks for the reply, actually this issues fix is there in my cluster, i am using knox 0.12.0.&lt;/P&gt;&lt;P&gt;i have &lt;STRONG&gt;httpclient-4.5.1.jar&lt;/STRONG&gt; in knox lib, and the issue you had mentioned has impacted WEBHDFS too, but for me WEBHDFS flow works , i am facing issue only with hive, &lt;/P&gt;</description>
      <pubDate>Wed, 29 Mar 2017 01:47:07 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175601#M58227</guid>
      <dc:creator>dsharma</dc:creator>
      <dc:date>2017-03-29T01:47:07Z</dc:date>
    </item>
    <item>
      <title>Re: knox to hivserver2 call does not work on ssl cluster</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175602#M58228</link>
      <description>&lt;P&gt;actually either there was something wrong in my clsuter or I had not restarted the knox after adding hive cert to the knox trust cacert. because after i lost the clsuter and created the new cluster and after doing necessary steps it worked, accepting your answer because the problem you shared was real issue that i had faced earlier with webhdfs , and was seeing the such issue.&lt;/P&gt;</description>
      <pubDate>Thu, 30 Mar 2017 18:20:15 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175602#M58228</guid>
      <dc:creator>dsharma</dc:creator>
      <dc:date>2017-03-30T18:20:15Z</dc:date>
    </item>
    <item>
      <title>Re: knox to hivserver2 call does not work on ssl cluster</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175603#M58229</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/505/dsharma.html" nodeid="505"&gt;@Deepak Sharma&lt;/A&gt; , when you say it worked, I am expecting, that you didn't do 2-way ssl and it's only one way by storing HS2 certificate in Knox host. Please confirm.&lt;/P&gt;</description>
      <pubDate>Thu, 30 Mar 2017 23:21:51 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175603#M58229</guid>
      <dc:creator>skoneru</dc:creator>
      <dc:date>2017-03-30T23:21:51Z</dc:date>
    </item>
    <item>
      <title>Re: knox to hivserver2 call does not work on ssl cluster</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175604#M58230</link>
      <description>&lt;P&gt;yes surya it was one way ssl&lt;/P&gt;</description>
      <pubDate>Fri, 31 Mar 2017 00:54:33 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/knox-to-hivserver2-call-does-not-work-on-ssl-cluster/m-p/175604#M58230</guid>
      <dc:creator>dsharma</dc:creator>
      <dc:date>2017-03-31T00:54:33Z</dc:date>
    </item>
  </channel>
</rss>

