HBase Testing Tutorial

Introduction

After you made some changes you have to run you HBase build for testing/debuging.

This tutorial is supposing that you have build your HBase project. If not, look through How to build HBase under Eclipse.

Starting Hadoop Core and ZooKeeper

HBase is working on top of Hadoop Core and using ZooKeeper service.

Your hadoop-site.xml should look like this:

<configuration>
  <property>
    <name>fs.default.name</name>
    <value>hdfs://localhost:9000</value>
  </property>
  <property>
    <name>mapred.job.tracker</name>
    <value>localhost:9001</value>
  </property>
  <property>
    <name>dfs.replication</name>
    <value>1</value>
  </property>
</configuration>

Your zoo.cfg should look like this:

tickTime=2000
initLimit=10
syncLimit=5
dataDir=/home/user/ZKDatadir
clientPort=2181

Configure hbase-site.xml

If you used my examples for Hadoop Core and ZooKeeper configuration, then your HBase/conf/hbase-site.xml should look like this:

<configuration>
  <property>
    <name>hbase.rootdir</name>
    <value>hdfs://localhost:9000/hbase</value>
  </property>
  <property>
    <name>hbase.master</name>
    <value>localhost:60000</value>
  </property>
  <property>
        <name>hbase.zookeeper</name>
        <value>localhost:2181//home/user/ZKDatadir</value>
  </property>
</configuration>

Resolving problem with webapps

Running HBase Master and Region Server

HBase is runned.

Also you can run it in debug mode.

Hbase/HowToTest (last edited 2012-11-28 08:34:36 by GabrielReid)