Validate HBase

Let us validate HBase installation by running few commands using HBase Shell.

  • On the gateway node of the hbase cluster run hbase shell
  • help command provides list of commands in different categories
  • Namespace – group of tables (similar to schema or database)
    • create – create_namespace 'training'
    • list – list_namespace 'training'
    • list tables – list_namespace_tables 'training'
  • Table – a group of rows which have keys and values
    • While creating the table we need to specify table name and at least one column family
    • Column family will have cells. A cell is nothing but, a name and value pair
    • e.g.: create 'training:hbasedemo', 'cf1'
    • list – list 'training:.*'
    • describe – describe 'training:hbasedemo'
    • truncate – truncate 'training:hbasedemo'
    • Dropping is 2 step process – disable and drop
    • disable – disable 'training:hbasedemo'
    • drop – drop 'training:hbasedemo'
  • Inserting/updating data

https://gist.github.com/dgadiraju/c9c1cc520239a783ee581b32dd626113

Share this post