依赖条件:需要有Hadoop,hive,zookeeper,hbase环境
映射:每一个在 Hive 表中的域都存在于 HBase 中,而在 Hive 表中不需要包含所有HBase 中的列。HBase 中的 RowKey 对应到 Hive 中为选择一个域使用 :key 来对应,列族(cf:)映射到 Hive 中的其它所有域,列为(cf:cq)
配置映射环境
一:先关闭所有服务
[root@siwen ~]# stop-hbase.sh -----关闭hbase
[root@siwen ~]# zkServer.sh stop -----关闭zookeeper
[root@siwen ~]# stop-alll.sh -----关闭hadoop
二:配置文件
1,修改host文件:
C:\Windows\System32\drivers\etc在此目录下的hosts文件把此机器的ip和hostname加入进去

2,修改hive-site.xml
[root@siwen ~]# cd /opt/soft/hive312/conf/
[root@siwen conf]# vim ./hive-site.xml
加入下面几行
<property>
<name>hive.zookeeper.quorum</name>
<value>192.168.255.159</value>
</property>
<property>
<name>hbase.zookeeper.quorum</name>
<value>192.168.255.159</value>
</property>
<property>
<name>hive.aux.jars.path</name>
<value>file:///opt/soft/hive312/lib/hive-hbase-handler-3.1.2.jar,file:///opt/soft/hive312/lib/zookeeper-3.4.6.jar,file:///opt/soft/hive312/lib/hbase-client-2.3.5.jar,file:///opt/soft/hive312/lib/hbase-common-2.3.5-tests.jar,file:///opt/soft/hive312/lib/hbase-server-2.3.5.jar,file:///opt