Using Hive with HBase
To allow Hive scripts to use HBase, proceed as follows.
- Install the hive-hbase package.
- Add the following statements to the top of each script. Replace the <Guava_version> string with the current version numbers for Guava. (You can
find current version numbers for CDH dependencies such as Guava in CDH's root pom.xml file for the current release, for example cdh-root-5.0.0.pom.)
ADD JAR /usr/lib/hive/lib/zookeeper.jar; ADD JAR /usr/lib/hive/lib/hive-hbase-handler.jar ADD JAR /usr/lib/hive/lib/guava-<Guava_version>.jar; ADD JAR /usr/lib/hive/lib/hbase-client.jar; ADD JAR /usr/lib/hive/lib/hbase-common.jar; ADD JAR /usr/lib/hive/lib/hbase-hadoop-compat.jar; ADD JAR /usr/lib/hive/lib/hbase-hadoop2-compat.jar; ADD JAR /usr/lib/hive/lib/hbase-protocol.jar; ADD JAR /usr/lib/hive/lib/hbase-server.jar; ADD JAR /usr/lib/hive/lib/htrace-core.jar;
Page generated July 8, 2016.
<< Starting HiveServer1 and the Hive Console | ©2016 Cloudera, Inc. All rights reserved | Using the Hive Schema Tool >> |
Terms and Conditions Privacy Policy |