Hbase0.98版本的安装部署配置管理(Hadoop2.3、Hbas(2)

<property>
<name>hbase.zookeeper.property.dataDir</name>
<value>/home/hadoop/zookeeper</value>
</property><property>
<name>hbase.zookeeper.quorum</name>
<value>192.168.52.128, 192.168.52.129, 192.168.52.130</value>
<description>指定ZooKeeper集群</description>
</property>

<property>
<name>hbase.master.info.bindAddress</name>
<value>192.168.52.128</value>
<description>The bind address for the HBase Master web UI
</description>
</property></configuration>

5.1),  配置

[root@name01 conf]# more hbase-site.xml

<?xml version="1.0"?>

<?xml-stylesheet type="text/xsl" href="https://www.linuxidc.com/configuration.xsl"?>

<!--

/**

*

* Licensed to the Apache Software Foundation (ASF) under one

* or more contributor license agreements.  See the NOTICE file

* distributed with this work for additional information

* regarding copyright ownership.  The ASF licenses this file

* to you under the Apache License, Version 2.0 (the

* "License"); you may not use this file except in compliance

* with the License.  You may obtain a copy of the License at

*

*   

*

* Unless required by applicable law or agreed to in writing, software

* distributed under the License is distributed on an "AS IS" BASIS,

* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

* See the License for the specific language governing permissions and

* limitations under the License.

*/

-->

<configuration>

<property>

<name>hbase.rootdir</name>

<value>hdfs://192.168.52.128:9000/hbase</value>

<description>HBase data directory</description>

</property>

<property>

<name>hbase.cluster.distributed</name>

<value>true</value>

<description>指定HBase运行的模式:false:单机/伪分布;true:完全分布</description>

</property>

<property>

<name>hbase.master</name>

<value>hdfs://192.168.52.128:60000</value>

<description>指定Master位置</description>

</property>

<property>

<name>hbase.zookeeper.property.dataDir</name>

<value>/home/hadoop/zookeeper</value>

</property><property>

<name>hbase.zookeeper.quorum</name>

<value>192.168.52.128, 192.168.52.129, 192.168.52.130</value>

<description>指定ZooKeeper集群</description>

</property>

<property>

<name>hbase.master.info.bindAddress</name>

<value>192.168.52.128</value>

<description>The bind address for the HBase Master web UI

</description>

</property>

</configuration>

[root@name01 conf]#

5.2),配置文件regionservers:

[root@name01 conf]# more regionservers

192.168.52.128

192.168.52.129

192.168.52.130

[root@name01 conf]#


5.3),设置环境变量hbase-env.sh:

vim hbase-env.sh

export JAVA_HOME=/usr/lib/jvm/jdk1.7.0_60

export HBASE_CLASSPATH=/home/hadoop/src/hbase-0.98.9-hadoop2/conf

export HBASE_HEAPSIZE=2048

export HBASE_MANAGES_ZK=false 

其中,JAVA_HOME表示java安装目录,HBASE_CLASSPATH指向存放有Hadoop配置文件的目录,这样HBase可以找到HDFS的配置信息,由于本文Hadoop和HBase部署在相同的物理节点,所以就指向了Hadoop安装路径下的conf目录。HBASE_HEAPSIZE单位为MB,可以根据需要和实际剩余内存设置,默认为1000。HBASE_MANAGES_ZK=false指示HBase使用已有的Zookeeper而不是自带的。

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/8df955ee10abe3847ec04699bdaaf3be.html