There appears to be a gap in the edit log. We expected txid 867311, but got txid 867402.
项目场景:集群断电之后重启集群,namenode启动失败,去hadoop安装目录差看日志/hadoop/logs发现There appears to be a gap in the edit log.We expected txid 867311, but got txid 867402.问题描述:down standby NN.java.io.IOException: There appears
·
项目场景:
集群断电之后重启集群,namenode启动失败,去hadoop安装目录差看日志
/hadoop/logs 发现There appears to be a gap in the edit log. We expected txid 867311, but got txid 867402.
问题描述:
down standby NN.
java.io.IOException: There appears to be a gap in the edit log. We expected txid 867311, but got txid 867402.
at org.apache.hadoop.hdfs.server.namenode.MetaRecoveryContext.editLogLoaderPrompt(MetaRecoveryContext.java:94)
at org.apache.hadoop.hdfs.server.namenode.FSEditLogLoader.loadEditRecords(FSEditLogLoader.java:218)
at org.apache.hadoop.hdfs.server.namenode.FSEditLogLoader.loadFSEdits(FSEditLogLoader.java:146)
at org.apache.hadoop.hdfs.server.namenode.FSImage.loadEdits(FSImage.java:891)
at org.apache.hadoop.hdfs.server.namenode.FSImage.loadEdits(FSImage.java:872)
at org.apache.hadoop.hdfs.server.namenode.ha.EditLogTailer.doTailEdits(EditLogTailer.java:262)
at org.apache.hadoop.hdfs.server.namenode.ha.EditLogTailer$EditLogTailerThread.doWork(EditLogTailer.java:395)
at org.apache.hadoop.hdfs.server.namenode.ha.EditLogTailer$EditLogTailerThread.access$300(EditLogTailer.java:348)
at org.apache.hadoop.hdfs.server.namenode.ha.EditLogTailer$EditLogTailerThread$1.run(EditLogTailer.java:365)
at org.apache.hadoop.security.SecurityUtil.doAsLoginUserOrFatal(SecurityUtil.java:481)
at org.apache.hadoop.hdfs.server.namenode.ha.EditLogTailer$EditLogTailerThread.run(EditLogTailer.java:361)
2020-12-07 16:45:36,940 INFO org.apache.hadoop.util.ExitUtil: Exiting with status 1: java.io.IOException: There appears to be a gap in the edit
log. We expected txid 867311, but got txid 867402.
解决方案:
1.进入安装hadoop目录bin下
执行:修复元数据
hadoop namenode –recover
选择Y
选择c
启动:
start-all.sh
更多推荐
已为社区贡献1条内容
所有评论(0)