版权声明:本文为博主原创文章,未经博主允许不得转载。https://www.jianshu.com/p/db2794a58168
解决HBASE Master启动失败记录
报错日志:
Exception in createBlockOutputStream
java.io.java.io.EOFException: Bad connect ack with firstBadLink as ip:50010
java.io.EOFException:Premature EOF: no length prefix available
……
Got an exception from the sync-loop
java.io.EOFEception:Premature EOF: no length prefix avaiable
at org.apache.hadoop.hdfs.protocolPB.PBHelper.vintPrefixed(PBHelper.java:2272)
at org.apache.hadoop.hdfs.DFSOutputStream$DataStreamer.createBlockOutputStream.java:1701)
……
Failed to become active master
java.lang.RuntimeException:sync aborted
at org.apache.hadoop.hbase.procedure2.store.wal.WALProcedureStore.pushData(WALProcedureStore.java:527)
……
1、尝试备份/hbase/WALs下的故障时间节点文件到本地,之后删除hdfs上的该文件,启动hbase master,可以在hbase实例中看到master的角色都已启动,但没有“活动”、“备用”状态,稍后服务自动停止;
2、新增/删除Master实例,再重启服务,结果同一;
3、由于hbase非正常启动,zookeeper还保留着上一次hbase版本的设置,造成了冲突,在zookeeper上没有把相应的/hbase节点注销,所以再次启动会报上面的错。解决方案:
登录zookeeper,删除/hbase节点。
[root@centOS1 conf]# zkCli.sh
[zk: localhost:2181(CONNECTED) 9] ls /
[hadoop-ha, hbase, zookeeper]
[zk: localhost:2181(CONNECTED) 11] delete /hbase
Node not empty: /hbase
[zk: localhost:2181(CONNECTED) 12] rmr /hbase
[zk: localhost:2181(CONNECTED) 13] ls /
[hadoop-ha, zookeeper]
网友评论