Hive Connector connection Timeout Using Kerberos Client Ticket

Hi,

Initially I got "Execute failed: Could not create connection to database: Unable to obtain Principal Name for authentication".

Followed the all the steps in the forum. 

Now I am getting "Execute Failed: Could not create connection to database: connection timed out: connect" error

Not sure why I am getting this error.

Am I suppose to use kinit command for JDBC driver

Following is the log;

DEBUG : KNIME-Worker-17 : WorkflowManager : Hive Connector : 0:25 : Hive Connector 0:25 doBeforePostExecution
DEBUG : KNIME-Worker-17 : NodeContainer : Hive Connector : 0:25 : Hive Connector 0:25 has new state: POSTEXECUTE
DEBUG : KNIME-Worker-17 : WorkflowManager : Hive Connector : 0:25 : Hive Connector 0:25 doAfterExecute - failure
DEBUG : KNIME-Worker-17 : Hive Connector : Hive Connector : 0:25 : reset
DEBUG : KNIME-Worker-17 : Hive Connector : Hive Connector : 0:25 : clean output ports.
DEBUG : KNIME-Worker-17 : WorkflowFileStoreHandlerRepository : Hive Connector : 0:25 : Removing handler 24160663-0e82-4cde-a30d-8d5793816252 (Hive Connector 0:25: <no directory>) - 0 remaining
DEBUG : KNIME-Worker-17 : NodeContainer : Hive Connector : 0:25 : Hive Connector 0:25 has new state: IDLE
DEBUG : KNIME-Worker-17 : HiveDriverDetector : Hive Connector : 0:25 : Using open source Hive driver: org.apache.hive.jdbc.HiveDriver
DEBUG : KNIME-Worker-17 : HiveConnectorNodeModel : Hive Connector : 0:25 : Using jdbc url: jdbc:hive2://XXXX.compute.amazonaws.com:10000/demo;principal=hive/XXXX.compute.amazonaws.com@XXXXAMAZON.LOCAL
DEBUG : KNIME-Worker-17 : Hive Connector : Hive Connector : 0:25 : Configure succeeded. (Hive Connector)
DEBUG : KNIME-Worker-17 : NodeContainer : Hive Connector : 0:25 : Hive Connector 0:25 has new state: CONFIGURED
DEBUG : KNIME-Worker-17 : Database SQL Executor : Database SQL Executor : 0:31 : Configure succeeded. (Database SQL Executor)
DEBUG : KNIME-Worker-17 : NodeContainer : Hive Connector : 0:25 : Logons to New or Unusual Systems 0 has new state: IDLE
DEBUG : KNIME-WFM-Parent-Notifier : NodeContainer :  :  : ROOT  has new state: IDLE
DEBUG : KNIME-Node-Usage-Writer : NodeTimer$GlobalNodeStats :  :  : Successfully wrote node usage stats to file: D:\Project\KNIME-Workspace\.metadata\knime\nodeusage_3.0.json

 

 

Hi,

the error message "Execute Failed: Could not create connection to database: connection timed out: connect" means that it was not posible for KNIME to make a network connection to the database. This is usually caused by a firewall blocking access to Hiveserver2 (running on port TCP/10000). Also you need to be able to make network connections to your Kerberos KDC (usually running on port UDP/88).

> Am I suppose to use kinit command for JDBC driver

Yes you need to do kinit or something equivalent outside of KNIME AP before you can connect to a Kerberos-secured cluster. We have a blog post that takes you through the steps of setting up KNIME Big Data Connectors for Kerberos:

https://www.knime.org/blog/speaking-kerberos-with-knime-big-data-extensions

Best,

Björn