Hbase高可用集群搭建

hadoop和spark高可用集群搭建参考链接:
http://www.jianshu.com/writer#/notebooks/6146839/notes/6304146

方案

192.168.211.129   elastic :        HMaster(主)
192.168.211.130   hbase :        Hmaster(备) RegionServer
192.168.211.131   mongodb :        RegionServer

配置Hbase

cd /home/spark/nosql/hbase-1.2.4/conf
vi hbase-env.sh
    export JAVA_HOME=/usr/java/default/
    export HBASE_MANAGES_ZK=false
vi hbase-site.xml
<configuration>
<property>
    <name>hbase.zookeeper.quorum</name>
    <value>elastic:2181,hbase:2181,mongodb:2181</value>
    <description>zookeeper server</description>
</property>
<property>
    <name>hbase.zookeeper.property.clientPort</name>
    <value>2181</value>
</property>
<property>
    <name>hbase.zookeeper.property.dataDir</name>
    <value>/home/spark/nosql/zookeeper-3.4.6/data</value>
    <description>Property from Zookeeper zoo.cfg</description>
</property>
<property>
    <name>hbase.rootdir</name>
    <value>hdfs://mycluster/hbase</value>
    <description>The directory shared by RegionServers.</description>
</property>
<property>
    <name>hbase.cluster.distributed</name>
    <value>true</value>
    <description>The mode the cluster will be in.</description>
</property>
</configuration>
vi regionservers
    hbase
    mongodb

启动

在主节点elastic:
    start-hbase.sh
在备节点hbase:
     hbase-daemon.sh start master

效果

elastic:
    14692 NameNode
    11385 JobHistoryServer
    16030 Jps
    14270 HMaster
    11521 ApplicationHistoryServer
    10281 JournalNode
    10098 QuorumPeerMain
    10216 DFSZKFailoverController
    14800 DataNode
    15094 ResourceManager
hbase:
    5813 NodeManager
    5250 NameNode
    5606 ResourceManager
    5486 DataNode
    9620 HRegionServer
    5071 DFSZKFailoverController
    10212 Jps
    4984 QuorumPeerMain
    6153 Worker
    5136 JournalNode
    9884 HMaster
    5987 Master
mongodb:
    3748 JournalNode
    5241 Jps
    4639 HRegionServer
    3701 QuorumPeerMain
    3836 DataNode
    3958 NodeManager
    原文作者:谜碌小孩
    原文地址: https://www.jianshu.com/p/43a9819b81f4
    本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系博主进行删除。
点赞