在hbase根目录下执行../hbase shell 进入hbase客户端操作窗口
HBase表的创建
# 语法:create <table>, {NAME => <family>, VERSIONS => <VERSIONS>}
# 例如:创建表t1,有两个family name:f1,f2,且版本数前者为1,后者为2
hbase(main)> create 't1',{NAME => 'f1', VERSIONS => 1},{NAME => 'f2', VERSIONS => 2}
HBase表的删除
- disable表
- drop表
hbase(main)> disable 't1'
hbase(main)> drop 't1'
HBase表的清空
hbase(main)> truncate 't1'