Hbase shell启动报错

本文记录了一次HBase客户端在尝试连接集群时遇到的连接丢失异常。通过详细的报错日志,我们逐步分析了可能的原因,并探讨了如何解决这类问题。文章涵盖了HBase客户端与ZooKeeper交互的过程,以及当ZooKeeper连接失败时的错误处理。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

报错日志
org.apache.zookeeper.KeeperExceptionConnectionLossException:KeeperErrorCode=ConnectionLossfor/hbase/hbaseidatorg.apache.zookeeper.KeeperException.create(KeeperException.java:99)atorg.apache.zookeeper.KeeperException.create(KeeperException.java:51)atorg.apache.zookeeper.ZooKeeper.exists(ZooKeeper.java:1045)atorg.apache.hadoop.hbase.zookeeper.RecoverableZooKeeper.exists(RecoverableZooKeeper.java:221)atorg.apache.hadoop.hbase.zookeeper.ZKUtil.checkExists(ZKUtil.java:482)atorg.apache.hadoop.hbase.zookeeper.ZKClusterId.readClusterIdZNode(ZKClusterId.java:65)atorg.apache.hadoop.hbase.client.ZooKeeperRegistry.getClusterId(ZooKeeperRegistry.java:86)atorg.apache.hadoop.hbase.client.ConnectionManagerHConnectionImplementation.retrieveClusterId(ConnectionManager.java:833)
at org.apache.hadoop.hbase.client.ConnectionManagerHConnectionImplementation.(ConnectionManager.java:623)atsun.reflect.NativeConstructorAccessorImpl.newInstance0(NativeMethod)atsun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)atsun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)atjava.lang.reflect.Constructor.newInstance(Constructor.java:422)atorg.apache.hadoop.hbase.client.ConnectionFactory.createConnection(ConnectionFactory.java:238)atorg.apache.hadoop.hbase.client.ConnectionFactory.createConnection(ConnectionFactory.java:218)atorg.apache.hadoop.hbase.client.ConnectionFactory.createConnection(ConnectionFactory.java:119)atsun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethod)atsun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)atsun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)atjava.lang.reflect.Method.invoke(Method.java:497)atorg.jruby.javasupport.JavaMethod.invokeDirectWithExceptionHandling(JavaMethod.java:450)atorg.jruby.javasupport.JavaMethod.invokeStaticDirect(JavaMethod.java:362)atorg.jruby.java.invokers.StaticMethodInvoker.call(StaticMethodInvoker.java:58)atorg.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:312)atorg.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:169)atorg.jruby.ast.CallOneArgNode.interpret(CallOneArgNode.java:57)atorg.jruby.ast.InstAsgnNode.interpret(InstAsgnNode.java:95)atorg.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)atorg.jruby.ast.BlockNode.interpret(BlockNode.java:71)atorg.jruby.evaluator.ASTInterpreter.INTERPRETMETHOD(ASTInterpreter.java:74)atorg.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:169)atorg.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:191)atorg.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:302)atorg.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:144)atorg.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:148)atorg.jruby.RubyClass.newInstance(RubyClass.java:822)atorg.jruby.RubyClassinewInstance.call(RubyClassinewInstance.gen:65535)atorg.jruby.internal.runtime.methods.JavaMethodJavaMethodZeroOrNBlock.call(JavaMethod.java:249)
at org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:292)
at org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:135)
at usr.lib.hbase_minus_1_dot_0_dot_3.bin.hirb.file(/usr/lib/hbase-1.0.3/bin/hirb.rb:118)
at usr.lib.hbase_minus_1_dot_0_dot_3.bin.hirb.load(/usr/lib/hbase-1.0.3/bin/hirb.rb)
at org.jruby.Ruby.runScript(Ruby.java:697)
at org.jruby.Ruby.runScript(Ruby.java:690)
at org.jruby.Ruby.runNormally(Ruby.java:597)
at org.jruby.Ruby.runFromMain(Ruby.java:446)
at org.jruby.Main.doRunFromMain(Main.java:369)
at org.jruby.Main.internalRun(Main.java:258)
at org.jruby.Main.run(Main.java:224)
at org.jruby.Main.run(Main.java:208)
at org.jruby.Main.main(Main.java:188)
2017-04-03 17:06:02,897 ERROR [main] zookeeper.ZooKeeperWatcher: hconnection-0x7d44a190x0, quorum=slave1:2181,master:2181, baseZNode=/hbase Received unexpected KeeperException, re-throwing exception
org.apache.zookeeper.KeeperExceptionConnectionLossException:KeeperErrorCode=ConnectionLossfor/hbase/hbaseidatorg.apache.zookeeper.KeeperException.create(KeeperException.java:99)atorg.apache.zookeeper.KeeperException.create(KeeperException.java:51)atorg.apache.zookeeper.ZooKeeper.exists(ZooKeeper.java:1045)atorg.apache.hadoop.hbase.zookeeper.RecoverableZooKeeper.exists(RecoverableZooKeeper.java:221)atorg.apache.hadoop.hbase.zookeeper.ZKUtil.checkExists(ZKUtil.java:482)atorg.apache.hadoop.hbase.zookeeper.ZKClusterId.readClusterIdZNode(ZKClusterId.java:65)atorg.apache.hadoop.hbase.client.ZooKeeperRegistry.getClusterId(ZooKeeperRegistry.java:86)atorg.apache.hadoop.hbase.client.ConnectionManagerHConnectionImplementation.retrieveClusterId(ConnectionManager.java:833)
at org.apache.hadoop.hbase.client.ConnectionManagerHConnectionImplementation.(ConnectionManager.java:623)atsun.reflect.NativeConstructorAccessorImpl.newInstance0(NativeMethod)atsun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)atsun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)atjava.lang.reflect.Constructor.newInstance(Constructor.java:422)atorg.apache.hadoop.hbase.client.ConnectionFactory.createConnection(ConnectionFactory.java:238)atorg.apache.hadoop.hbase.client.ConnectionFactory.createConnection(ConnectionFactory.java:218)atorg.apache.hadoop.hbase.client.ConnectionFactory.createConnection(ConnectionFactory.java:119)atsun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethod)atsun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)atsun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)atjava.lang.reflect.Method.invoke(Method.java:497)atorg.jruby.javasupport.JavaMethod.invokeDirectWithExceptionHandling(JavaMethod.java:450)atorg.jruby.javasupport.JavaMethod.invokeStaticDirect(JavaMethod.java:362)atorg.jruby.java.invokers.StaticMethodInvoker.call(StaticMethodInvoker.java:58)atorg.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:312)atorg.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:169)atorg.jruby.ast.CallOneArgNode.interpret(CallOneArgNode.java:57)atorg.jruby.ast.InstAsgnNode.interpret(InstAsgnNode.java:95)atorg.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)atorg.jruby.ast.BlockNode.interpret(BlockNode.java:71)atorg.jruby.evaluator.ASTInterpreter.INTERPRETMETHOD(ASTInterpreter.java:74)atorg.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:169)atorg.jruby.internal.runtime.methods.DefaultMethod.call(DefaultMethod.java:191)atorg.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:302)atorg.jruby.runtime.callsite.CachingCallSite.callBlock(CachingCallSite.java:144)atorg.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:148)atorg.jruby.RubyClass.newInstance(RubyClass.java:822)atorg.jruby.RubyClassinewInstance.call(RubyClassinewInstance.gen:65535)atorg.jruby.internal.runtime.methods.JavaMethodJavaMethodZeroOrNBlock.call(JavaMethod.java:249)
at org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:292)
at org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:135)
at usr.lib.hbase_minus_1_dot_0_dot_3.bin.hirb.file(/usr/lib/hbase-1.0.3/bin/hirb.rb:118)
at usr.lib.hbase_minus_1_dot_0_dot_3.bin.hirb.load(/usr/lib/hbase-1.0.3/bin/hirb.rb)
at org.jruby.Ruby.runScript(Ruby.java:697)
at org.jruby.Ruby.runScript(Ruby.java:690)
at org.jruby.Ruby.runNormally(Ruby.java:597)
at org.jruby.Ruby.runFromMain(Ruby.java:446)
at org.jruby.Main.doRunFromMain(Main.java:369)
at org.jruby.Main.internalRun(Main.java:258)
at org.jruby.Main.run(Main.java:224)
at org.jruby.Main.run(Main.java:208)
at org.jruby.Main.main(Main.java:188)
HBase Shell; enter ‘help’ for list of supported commands.
Type “exit” to leave the HBase Shell
Version 1.0.3, rf1e1312f9790a7c40f6a4b5a1bab2ea1dd559890, Tue Jan 19 19:26:53 PST 2016

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值