zoukankan      html  css  js  c++  java
  • hbase distributed setup and configuration

    1 ensure the same operating system , authentication , JDK installation path on every mainframe computers
    2 vim /etc/hosts, add ip hostname in the shape of key/value,hostname should be unique,localhost should be deleted(!!important)
    3 open ssh service,ensure all the mainframe computers can access each other without password
    4 setup hadoop
      Export HADOOP_HOME=hadoop installation path
      Export PATH=$HADOOP_HOME/bin:$PATH


    5 hadoop configuration
      (1) conf/hadoop-env.sh
          export JAVA_HOME=JDK installation path
      (2) add master ip into conf/masters,each ip at single line
          add slave ip into conf/slaves,each ip at single line
      (3) core-site.xml
     <configuration>
      <property>
       <name>hadoop.tmp.dir</name>
       <value>hadoop installation path</value>
      </property>
      <property>
       <name>fs.default.name</name>
       <value>hdfs://masterIP:9000(any not used port)</value>
      </property>
     </configuration>
    (4) hdfs-site.xml
     <configuration>
      <property>
       <name>dfs.replication</name>
       <value>datanode num</value>
      </property>
      <property>
       <name>dfs.name.dir</name>
       <value>/tmp/dfs/name</value>
      </property>
      <property>
       <name>dfs.data.dir</name>
       <value>/tmp/dfs/data</value>
      </property> 
     </configuration>
     (5) mapred-site.xml
     <configuration>
      <property>
       <name>mapred.job.tracker</name>
       <value>masterIP:9001</value>
      </property>
     </configuration>


    6 hbase configuration
      (1)conf/regionservers insert data like slaves configuration in hadoop
      (2)hbase-env.sh
         export JAVA_HOME=JDK installation path
         export HBASE_MANAGES_ZK=true
      (3)hbase-site.xml
     <configuration>
       <property>
      <name>hbase.rootdir</name>
      <value>hdfs://hadoopmasterip:9000/hbase</value>
       </property>
       <property>
      <name>hbase.cluster.distributed</name>
      <value>true</value>
       </property>
       <property>
      <name>hbase.master</name>
      <value>hbasemasterip:60000</value>
       </property>
       <property>
      <name>hbase.zookeeper.quorum</name>
      <value>any one regionserversIP(num should be odd)</value>
       </property>
     </configuration>

    notice
      1 software version
         hadoop-1.0.4 hbase-0.94.7
      2 how to get jdk installation path
         update-alternatives --display java
         java_home /usr/lib/jvm/jre-1.6.0-openjdk.x86_64
      3 how to stop hbase
         on slave ./hbase-daemon.sh stop regionserver
         on master ./stop-hbase.sh

  • 相关阅读:
    第一节 2字符串 简单
    第一节 1C#基础 简单
    终于找到wamp修改密码方式了!
    js通过class name获得元素
    JavaScript中arguments
    对技术的态度
    C++的坑真的多吗?
    js 常用正则
    js利用Array.splice实现Array的insert/remove
    c# asp.net webform web页面打印,可以控制需要打印和不需要打印的位置
  • 原文地址:https://www.cnblogs.com/ai464068163/p/3064554.html
Copyright © 2011-2022 走看看