Obtain and Install Drivers for Hive and Impala

To obtain JDBC drivers for Hive and Impala

1. From the web, locate the Hive zip files.

For example, download locations are:

https://archive.apache.org/dist/hive/hive-0.<version>.0/
https://www.cloudera.com/downloads/connectors/hive/jdbc/2-5-12.html

For example:

Do a web search and download hive-0.<version>.0-bin.tar.gz.

Or query and follow instructions retrieved at:

Hive 0.13 JDBC driver with Kerberos, https://querysurge.zendesk.com/hc/en-us/articles/115001218863-Setting-Up-a-Hive-Connection-with-Kerberos-using-Apache-JDBC-Drivers-Windows-
https://streever.atlassian.net/wiki/spaces/HADOOP/pages/4390924
2. Unpack the zip file.
3. Copy the following JAR files for your version

Version

JAR Files

Impala 2.0 with Kerberos

commons-collections-3.2.1.jar
commons-configuration-1.6.jar
commons-logging-1.1.3.jar
Core-Site.jar(core-site.jar file is required for the TRUSTED_DELEGATION case when the “default_realm” is not the login realm.)
guava-11.0.2.jar
hadoop-auth-2.5.0-cdh5.3.0.jar
hadoop-common-2.5.2.jar
hadoop-mapreduce-client-core-2.5.0-cdh5.3.0.jar
hive-exec-1.0.0.jar
hive-jdbc-1.0.0.jar
hive-service-1.0.0.jar
httpclient-4.2.5.jar
httpcore-4.2.5.jar
libfb303-0.9.0.jar
libthrift-0.9.0.jar
log4j-1.2.16.jar
slf4j-api-1.7.5.jar
slf4j-log4j12-1.7.5.jar

Impala 2.0

hadoop-core-1.2.1.jar
commons-logging-1.1.3.jar
hive-exec-0.13.1-cdh5.3.0.jar
hive-jdbc-0.13.1-cdh5.3.0.jar
hive-metastore-0.13.1-cdh5.3.0.jar
hive-service-0.13.1-cdh5.3.0.jar
httpclient-4.2.5.jar
httpcore-4.2.5.jar
libfb303-0.9.0.jar
libthrift-0.9.0.jar
log4j-1.2.17.jar
slf4j-api-1.7.5.jar
slf4j-log4j12-1.7.5.jar

Impala 1.0

commons-configuration-1.6.jar
commons-logging-1.0.4.jar
Core-Site.jar
hadoop-core-1.2.1.jar
hive-exec-0.11.0.1.3.3.4-2.jar
hive-jdbc-0.11.0.1.3.3.4-2.jar
hive-service-0.11.0.1.3.3.4-2.jar
libfb303-0.9.0.jar
libthrift-0.9.0.jar
log4j-1.2.16.jar
slf4j-api-1.6.1.jar
slf4j-log4j12-1.7.5.jar

Apache Impala 2.x

slf4j-log4j12-1.7.5.jar
slf4j-api-1.7.5.jar
log4j-1.2.16.jar
libthrift-0.9.0.jar
libfb303-0.9.0.jar
httpcore-4.2.5.jar
httpclient-4.2.5.jar
hive-service-1.0.0.jar
hive-jdbc-1.0.0.jar
hive-exec-1.0.0.jar
hadoop-common-2.5.2.jar
commons-logging-1.1.3.jar

Cloudera Impala 2.7

commons-codec-1.3.jar
commons-logging-1.1.1.jar
hive_metastore.jar
hive_service.jar
httpclient-4.1.3.jar
httpcore-4.1.3.jar
ImpalaJDBC4.jar
libfb303-0.9.0.jar
libthrift-0.9.0.jar
log4j-1.2.14.jar
ql.jar
slf4j-api-1.5.11.jar
slf4j-log4j12-1.5.11.jar
TCLIServiceClient.jar
zookeeper-3.4.6.jar

Cloudera Hive 1.1

commons-codec-1.3.jar
commons-logging-1.1.1.jar
HiveJDBC4.jar
hive_metastore.jar
hive_service.jar
httpclient-4.1.3.jar
httpcore-4.1.3.jar
libfb303-0.9.0.jar
libthrift-0.9.0.jar
log4j-1.2.14.jar
ql.jar
slf4j-api-1.5.11.jar
slf4j-log4j12-1.5.11.jar
TCLIServiceClient.jar
zookeeper-3.4.6.jar

Apache Hive 1.1.0

commons-logging-1.1.3.jar
hadoop-common-2.5.2.jar
hive-exec-1.1.0.jar
hive-jdbc-1.1.0.jar
hive-service-1.1.0.jar
httpclient-4.5.3.jar
httpcore-4.2.5.jar
libfb303-0.9.2.jar
libthrift-0.9.2.jar
log4j-1.2.16.jar
slf4j-api-1.7.5.jar
slf4j-log4j12-1.7.5.jar

Apache Hive 2.x

commons-cli-1.2.jar
commons-configuration-1.6.jar
commons-logging-1.2.jar
hadoop-auth-2.7.3.jar
hadoop-common-2.7.3.jar
hadoop-hdfs-2.7.3.jar
hive-exec-2.1.1.jar
hive-jdbc-2.1.1.jar
hive-service-2.1.1.jar
htrace-core-3.1.0-incubating.jar
httpclient-4.4.jar
httpcore-4.4.jar
libfb303-0.9.3.jar
libthrift-0.9.3.jar
log4j-core-2.4.1.jar
4. From the Apache Hadoop web site, locate and copy the hadoop-core-1.2.1.jar file.

To install the JDBC drivers for Hive and Impala

Make sure to add the JAR files to all of your TDV clients and servers.

5. Paste the necessary driver JAR files into one or more of the following TDV installation directories:
<TDV_install_dir>\conf\adapters\system\hive_0_10_hiveserver2 
<TDV_install_dir>\conf\adapters\system\hive_0_12_hiveserver2 
<TDV_install_dir>\conf\adapters\system\impala_0_6 
<TDV_install_dir>\conf\adapters\system\hive2 
<TDV_install_dir>/conf/adapters/system/hive_0_13_hiveserver2
<TDV_install_dir>/conf/adapters/system/hive_0_14_hiveserver2
6. Restart the TDV Server.

To enable Kerberos authentication:

7. Configure the following JDBC connection URL to authenticate the connecting user with Kerberos:
jdbc:hive2://<host>:<port>/<dbName>;principal=<HiveServer2_kerberos_principal>;<otherSessionConfs>?<hiveConfs>#<hiveVars>