Fully Distributed hbase-0.98.1-cdh5.1.0 Construction

Source: Internet
Author: User

The configuration of CDH is the same as that of version 0.98.


1. Environment

MASTER: C1
SLAVE: C2, C3

Centos 6.5x64, hadoop-2.3.0-cdh5.1.0, zookeeper-3.4.5-cdh5.1.0

:

Http://archive.cloudera.com/cdh5/cdh/5/

2. Prerequisites

Install hadoop cluster and zookeeper Cluster

3. environment variable configuration

export HBASE_HOME=/usr/local/cdh/hbaseexport PATH=$PATH:$HADOOP_HOME/bin:$HBASE_HOME/bin:$ZOOKEEPER_HOME/bin

4. Configure hbase-env.sh

Add in $ hbase_home/CONF/hbase-env.sh


export JAVA_HOME=/usr/local/java/jdk1.7.0_67 export HBASE_CLASSPATH=/usr/local/cdh/hadoop/etc/hadoopexport HBASE_MANAGES_ZK=false


5. Configure hbase-site.xml

<configuration><property>    <name>hbase.rootdir</name>    <value>hdfs://c1:9000/hbase</value>  </property><property>  <name>hbase.cluster.distributed</name>  <value>true</value>  </property> <property>  <name>hbase.zookeeper.quorum</name>  <value>c1,c2,c3</value> </property>  <property>    <name>hbase.zookeeper.property.dataDir</name>    <value>/usr/local/cdh/zookeeper/data/</value>  </property> <property>  <name>hbase.master</name>  <value>hdfs://c1:60000</value> </property></configuration>


The preceding configurations are described as follows:

Hbase. rootdir: hbase data storage directory (HDFS directory)

Hbase. Cluster. distributed: Specifies whether hbase runs in distributed mode.

Hbase. zookeeper. Property. datadir: zookeeper write data directory (consistent with the configuration on the zookeeper cluster)

Hbase. zookeeper. quorun: specify that hbase enables and manages a zookeeper instance on each node, that is, specify the zookeeper cluster location.
Hbase. Master: Specifies the master location of hbase.

6. Configure regionservers

The regionservers file lists all machines running hbase regionserver chregion server. The configuration of this file is very similar to that of the hadoop slaves file. Each line specifies a machine. When hbase is enabled, all machines listed in this file are started. When hbase is disabled, the file is automatically read and all machines are disabled.
Delete localhost and add

c1c2c3

7. Create $ hbase_home/CONF/backup-masters

c2

8. Make the same configurations for other nodes.

scp -r hbase-0.98.4-hadoop2 c2:~/

scp -r hbase-0.98.4-hadoop2 c3:~/

9. Start and view Processes

1. Start

The starting sequence of hbase is: HDFS-> zookeeper-> hbase

Master node:

Start the hadoop cluster in the $ hadoop_home directory

sbin/start-all.sh

Each node:

Start the zookeeper cluster in the $ zookeeper_home directory

bin/zkServer.sh start

Master node:

Start the hbase cluster in the $ hbase_home directory

bin/start-hbase.sh

2. View commands

Master Node

[[email protected] hbase]# jps6382 QuorumPeerMain5724 NameNode5912 SecondaryNameNode7666 Jps6089 ResourceManager6580 HMaster6713 HRegionServer

Slave node:

[[email protected] zookeeper]# jps5087 HRegionServer4681 DataNode5326 Jps5156 HMaster4974 QuorumPeerMain4807 NodeManager


Fully Distributed hbase-0.98.1-cdh5.1.0 Construction

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.