Hive UI(HWI)
Hive
Web Interface(HWI)简介:Hive自带了一个Web-GUI
编辑文件conf/hive-site.xml,添加hive.hwi.war.file的配置:
<property>
<name>hive.hwi.listen.host</name>
<value>0.0.0.0</value>
<description>This is the host address the Hive Web Interface will listen on</description>
</property>
<property>
<name>hive.hwi.listen.port</name>
<value>9999</value>
<description>This is the port the Hive Web Interface will listen on</description>
</property>
<property>
<name>hive.hwi.war.file</name>
<value>lib/hive-hwi-1.2.1.war</value>
<description>This sets the path to the HWI war file, relative to ${HIVE_HOME}. </description>
</property>
$ sh bin/hive --service hwi
----------------------------------------------------------------------------------------------------
没有UI war包的,需要自己下载对应版本的源码进行打包,后拷到lib下。
将源码解压:
tar -vxzf apache-hive-1.2.1-src.tar.gz
进入解压后的目录,再进入hwi目录下:
cd apache-hive-1.2.1-src/hwi/
生成war包:
jar cvM hive-hwi-1.2.1.war -C web .
将生成的war包,拷贝到hive的lib目录下,重启hwi服务,。
若有如下报错,需将jre下的tools.jar包拷到Hive的lib目录下,重启hwi服务:
cp /usr/java/jdk1.7.0_79/lib/tools.jar /home/Big.Data/Hive/apache-hive-1.2.1-bin/lib/.
sh bin/hive --service hwi
----------------------------------------------------------------------------------------------------------------------
Problem accessing /hwi/. Reason:
Unable to find a javac compiler;
com.sun.tools.javac.Main is not on the classpath.
Perhaps JAVA_HOME does not point to the JDK.
It is currently set to "/usr/java/jdk1.7.0_79/jre"