HBase在Hadoop上的最新安装教程



                                HBase安装教程

  1. 在官网是下载hbase-1.3.1-bin.tar.gz (不用解压)

     

  2. hbase-1.3.1-bin.tar.gz上传到虚拟机的-C /usr/local目录下

     

  3. 解压hbase-1.3.1-bin.tar.gzusr/local/apps目录下,命令:tar -zxvf hbase-1.3.1-bin.tar.gz  -C /usr/local/apps/

     

  4.  cd usr/local/apps/hbase-1.3.1/conf目录下,运行vi hbase-env.sh

    添加

    export JAVA_HOME=/usr/local/apps/jdk1.8  //Java路径

    export HBASE_MANAGES_ZK=false

    保存离开

     

  5.  vi hbase-site.xml末尾添加代码,保存离开

  

    hbase.rootdir

    hdfs://hdp-node-01:9000/hbase

  

  

    hbase.cluster.distributed

    true

  

  

    hbase.zookeeper.property.dataDir

    /usr/local/apps/zookeeper-3.4.8/data

  

  

    hbase.zookeeper.quorum

    192.168.239.102,192.168.239.103,192.168.239.104

  

  

    hbase.zookeeper.property.clientPort

    2080

  

  

    hbase.unsafe.stream.capability.enforce

    true

    

      Controls whether HBase will check for stream capabilities (hflush/hsync).

 

      Disable this if you intend to run on LocalFileSystem, denoted by a rootdir

      with the 'file://' scheme, but be mindful of the NOTE below.

 

      WARNING: Setting this to false blinds you to potential data loss and

      inconsistent system state in the event of process and/or node failures. If

      HBase is complaining of an inability to use hsync or hflush it's most

      likely not a false positive.

    

  

 

  1.  hbase-1.3.1文件传给从节点

    scp -r hbase-1.3.1 hdp-node-02:/usr/local/apps/

    scp -r hbase-1.3.1 hdp-node-03:/usr/local/apps/

    scp -r hbase-1.3.1 hdp-node-04:/usr/local/apps/

     

  2.  刷新source /etc/profile,在bin/start-hbase.sh打开hbase

     

  3. Jps主节点

     HBase在Hadoop上的最新安装教程_第1张图片

    Jps从节点

     HBase在Hadoop上的最新安装教程_第2张图片

    http://IP:16010/master-status查看web界面

     HBase在Hadoop上的最新安装教程_第3张图片

    安装成功

  4. 为了以后方便,我们需要对环境变量进行配置

       su root

        vi /etc/profile 在里面添加

        export HBASE_HOME=/usr/local/apps/hbase-1.3.1

        export PATH=$PATH:$HBASE_HOME/bin

保存离开

以后即使在其他目录下,也可以启动hbase了



你可能感兴趣的:(大数据)