ERROR: Can't get master address from ZooKeeper; znode data == null

2 篇文章 0 订阅
1 篇文章 0 订阅

最近配置HBASE+ZOOKEEPER的时候,运行list的时候报下面错误:

 

 

hbase(main):001:0> list
TABLE                                                                                                                                                                           

ERROR: Can't get master address from ZooKeeper; znode data == null

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> list 'ns:abc.*'
  hbase> list 'ns:.*'

 

 

网上的方式尝试之后均无法解决,最后发现是因为我修改了unbuntu的host文件配置导致的:

失败时的配置:

127.0.0.1    localhost

127.0.0.1    S01

192.168.159.128    S01


# The following lines are desirable for IPv6 capable hosts
#::1     localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters

这个配置的时候启动hadoop正常,JPS看不出任何问题,但是在运行hadoop fs -ls查看hdfs文件系统的时候报一下错误:

root@S01:~# hadoop fs -ls
15/12/04 18:53:59 WARN ipc.Client: Address change detected. Old: S01/192.168.159.128:9000 New: S01/127.0.1.1:9000
ls: Call From S01/127.0.1.1 to S01:9000 failed on connection exception: java.net.ConnectException: Connection refused; For more details see:  http://wiki.apache.org/hadoop/ConnectionRefused

 

然后我把hosts文件修改成下面的内容后,报错解决,HBASE也完全正常了

 

127.0.0.1    localhost


# The following lines are desirable for IPv6 capable hosts
::1     localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters

 

查了相关资料后发现,可能hadoop默认使用ipv6连接,而我禁用了IPV6导致上述问题

http://www.d1net.com/bigdata/news/329178.html

 

 

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

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值