Home > HBase > HBase installation on Ubuntu

HBase installation on Ubuntu

Steps to install HBase on Ubuntu Machine:

  1. Download latest Hbase  from http://hbase.apache.org/
  2. extract it to hbase
  3. Set JAVA_HOME variable in conf/hbase-env.sh
  4. Add hbase/bin to PATH variable
  5. go to hbase folder
  6. $bin/hbase  if it is giving some thing means hbase installed correctly

Start and Stop the HBase:

  1. Start the hbase : $bin/hbase start-hbase.sh
  2. Stop the hbase : $bin/hbase stop-hbase.sh // this will take time and remember stop the hadoop first and then stop the hbase.

HBase Shell Commands:

  1. $bin/hbase shell run this command to enter into hbase shell
  2. To see list of tables created in hbase $bin/hbase list
  3. To create a table in hbase  $create ‘test’,’cf’
  4. Insert some values into the above created test $put ‘test’,’row1’,’cf:a’,’value1’
  5. To see the data $ scan ‘test’
  6. To get one row from the hbase table $ get ‘test’,’row1’.

To Delete Hbase table:

  1. after disabling we can able to drop it $disable ‘test’ and then $drop ‘test’

Hope it helps.

Thanks.

Advertisements
Categories: HBase
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: