HBase常用命令

HBase常用命令status, version, table_help和whoami。本章将介绍了这些命令。

status

命令返回包括在系统上运行的服务器的细节和系统的状态。它的语法如下:

hbase(main):009:0> status

如果执行这个命令,它会返回下面的输出

hbase(main):009:0> status
3 servers, 0 dead, 1.3333 average load
version

该命令返回HBase系统使用的版本。它的语法如下:

hbase(main):010:0> version
如果执行这个命令,它会返回下面的输出。
hbase(main):009:0> version
0.98.8-hadoop2, r6cfc8d064754251365e070a10a82eb169956d5fe, Fri Nov 14
18:26:29 PST 2014
table_help

此命令将引导如何使用表引用的命令。下面给出的是使用这个命令的语法。

hbase(main):02:0> table_help
当使用此命令时,它显示帮助主题表相关的命令。下面给出是此命令的部分输出。
hbase(main):002:0> table_help
Help for table-reference commands.
You can either create a table via 'create' and then manipulate the table
via commands like 'put', 'get', etc.
See the standard help information for how to use each of these commands.
However, as of 0.96, you can also get a reference to a table, on which
you can invoke commands.
For instance, you can get create a table and keep around a reference to
it via:
 hbase> t = create 't', 'cf'…...

whoami

该命令返回HBase用户详细信息。如果执行这个命令,返回当前HBase用户,如下图所示

hbase(main):008:0> whoami
hadoop (auth:SIMPLE)
groups: hadoop
联系我们

邮箱 626512443@qq.com
电话 18611320371(微信)
QQ群 235681453

Copyright © 2015-2022

备案号:京ICP备15003423号-3