天天看点

Hue集成Hbase

        本篇博客,小菌为大家带来的是Hue集成Hbase的分享。

1.修改hbase配置

hbase-site.xml

配置文件中的添加如下内容,开启hbase thrift服务。

修改完成之后scp给其他机器上hbase安装包。

<property>
  <name>hbase.thrift.support.proxyuser</name>
  <value>true</value>
</property>
<property>
  <name>hbase.regionserver.thrift.http</name>
  <value>true</value>
</property>
           

2.修改hadoop配置

core-site.xml

中确保 HBase被授权代理,添加下面内容。

把修改之后的配置文件scp给其他机器和hbase安装包conf目录下。

<property>
<name>hadoop.proxyuser.hbase.hosts</name>
<value>*</value>
</property>
<property>
<name>hadoop.proxyuser.hbase.groups</name>
<value>*</value>
</property>
           

如果在安装hbase时,conf目录下的core-site.xml采用的软连接的方式,这一步的配置文件分发就不需要发送至hbase安装包conf目录下

3.修改Hue配置

cd /export/servers/hue-3.9.0-cdh5.14.0/desktop/conf

vim hue.ini 大约在1244行

修改如下部分内容

[hbase]
  # Comma-separated list of HBase Thrift servers for clusters in the format of '(name|host:port)'.
  # Use full hostname with security.
  # If using Kerberos we assume GSSAPI SASL, not PLAIN.
  ##  node01你的安装hbase的主节点
  hbase_clusters=(Cluster|node01:9090)

  # HBase configuration directory, where hbase-site.xml is located.
  #  ## 你的hbase的安装配置路径
  hbase_conf_dir=/export/servers/hbase-1.2.0-cdh5.14.0/conf
  # Hard limit of rows or columns per row fetched before truncating.
  ## truncate_limit = 500

  # 'buffered' is the default of the HBase Thrift Server and supports security.
  # 'framed' can be used to chunk up responses,
  # which is useful when used in conjunction with the nonblocking server in Thrift.
  thrift_transport=buffered
           

4.启动hbase(包括thrift服务),hue

需要启动hdfs和hbase,然后再启动thrift。

start-dfs.sh

start-hbase.sh

hbase-daemon.sh start thrift