: org.apache.hadoop.hbase.MasterNotRunningException: Retried 7 times解决方案

[grid@master ~]$ hbase shell

HBase Shell; enter 'help<RETURN>' for list of supported commands.

Type "exit<RETURN>" to leave the HBase Shell

Version 0.94.1, r1365210, Tue Jul 24 18:40:10 UTC 2012

hbase(main):001:0> create 't1', 'f1', 'f2', 'f3'

ERROR: org.apache.hadoop.hbase.MasterNotRunningException: Retried 7 times

Here is some help for this command:

Create table; pass table name, a dictionary of specifications per

column family, and optionally a dictionary of table configuration.

Dictionaries are described below in the GENERAL NOTES section.

Examples:

  hbase> create 't1', {NAME => 'f1', VERSIONS => 5}

  hbase> create 't1', {NAME => 'f1'}, {NAME => 'f2'}, {NAME => 'f3'}

  hbase> # The above in shorthand would be the following:

  hbase> create 't1', 'f1', 'f2', 'f3'

  hbase> create 't1', {NAME => 'f1', VERSIONS => 1, TTL => 2592000, BLOCKCACHE => true}

  hbase> create 't1', 'f1', {SPLITS => ['10', '20', '30', '40']}

  hbase> create 't1', 'f1', {SPLITS_FILE => 'splits.txt'}

  hbase> # Optionally pre-split the table into NUMREGIONS, using

  hbase> # SPLITALGO ("HexStringSplit", "UniformSplit" or classname)

  hbase> create 't1', 'f1', {NUMREGIONS => 15, SPLITALGO => 'HexStringSplit'}

hbase(main):002:0> lq

NameError: undefined local variable or method `lq' for #<Object:0x639d0e0b>

hbase(main):003:0> exit

[grid@master conf]$ hadoop dfsadmin -safemode leave

Safe mode is OFF

[grid@master conf]$

[grid@master lib]$ hbase shell

HBase Shell; enter 'help<RETURN>' for list of supported commands.

Type "exit<RETURN>" to leave the HBase Shell

Version 0.94.1, r1365210, Tue Jul 24 18:40:10 UTC 2012

hbase(main):001:0> list

TABLE                                                                                    

ERROR: org.apache.hadoop.hbase.MasterNotRunningException: Retried 7 times

Here is some help for this command:

List all tables in hbase. Optional regular expression parameter could

be used to filter the output. Examples:

  hbase> list

  hbase> list 'abc.*'

hbase(main):002:0> list

TABLE                                                                                    

0 row(s) in 5.2580 seconds

hbase(main):003:0>

解决办法:A:如果rootdir配置的是使用hdfs,检查是否hdfs服务进程没有打开,请启动hadoop

                 B:确认hadoop已经启动,请检查hbasehadoop的版本是否不一致,将hbase/lib目录下的hadoop-corejar文件删除,将hadoop目录下的hadoop-0.20.2-core.jar拷贝到hbase/lib下面,然后重新启动hbase即可。

C:可能hadoop启动的事安全模式,执行 :/bin$ hadoop dfsadmin -safemode leave   即可。

  解决这样的问题请查看hbase的日志文件,从日志文件着手。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值