文档章节

Unable to load database on disk

刀锋
 刀锋
发布于 06/25 19:17
字数 455
阅读 30
收藏 0

由于磁盘空间满了以后,导致zookeeper异常退出,清理磁盘空间后,zk启动报错,信息如下: 

2018-06-25 17:18:46,904 INFO org.apache.zookeeper.server.quorum.QuorumPeerConfig: Reading configuration from: /run/cloudera-scm-agent/process/447-zookeeper-server/zoo.cfg
2018-06-25 17:18:46,934 INFO org.apache.zookeeper.server.quorum.QuorumPeerConfig: Defaulting to majority quorums
2018-06-25 17:18:46,939 INFO org.apache.zookeeper.server.DatadirCleanupManager: autopurge.snapRetainCount set to 5
2018-06-25 17:18:46,939 INFO org.apache.zookeeper.server.DatadirCleanupManager: autopurge.purgeInterval set to 24
2018-06-25 17:18:46,962 INFO org.apache.zookeeper.server.quorum.QuorumPeerMain: Starting quorum peer
2018-06-25 17:18:46,971 INFO org.apache.zookeeper.server.DatadirCleanupManager: Purge task started.
2018-06-25 17:18:46,998 INFO org.apache.zookeeper.server.DatadirCleanupManager: Purge task completed.
2018-06-25 17:18:47,001 INFO org.apache.zookeeper.server.NIOServerCnxnFactory: binding to port 0.0.0.0/0.0.0.0:2181
2018-06-25 17:18:47,035 INFO org.apache.zookeeper.server.quorum.QuorumPeer: minSessionTimeout set to 4000
2018-06-25 17:18:47,035 INFO org.apache.zookeeper.server.quorum.QuorumPeer: maxSessionTimeout set to 60000
2018-06-25 17:18:47,036 INFO org.apache.zookeeper.server.quorum.QuorumPeer: QuorumPeer communication is not secured!
2018-06-25 17:18:47,038 INFO org.apache.zookeeper.server.quorum.QuorumPeer: quorum.cnxn.threads.size set to 20
2018-06-25 17:18:47,040 INFO org.apache.zookeeper.server.persistence.FileSnap: Reading snapshot /var/lib/zookeeper/version-2/snapshot.e00000000
2018-06-25 17:18:47,195 ERROR org.apache.zookeeper.server.quorum.QuorumPeer: Unable to load database on disk
java.io.EOFException
        at java.io.DataInputStream.readInt(DataInputStream.java:392)
        at org.apache.jute.BinaryInputArchive.readInt(BinaryInputArchive.java:63)
        at org.apache.zookeeper.server.persistence.FileHeader.deserialize(FileHeader.java:64)
        at org.apache.zookeeper.server.persistence.FileTxnLog$FileTxnIterator.inStreamCreated(FileTxnLog.java:594)
        at org.apache.zookeeper.server.persistence.FileTxnLog$FileTxnIterator.createInputArchive(FileTxnLog.java:613)
        at org.apache.zookeeper.server.persistence.FileTxnLog$FileTxnIterator.goToNextLog(FileTxnLog.java:579)
        at org.apache.zookeeper.server.persistence.FileTxnLog$FileTxnIterator.next(FileTxnLog.java:661)
        at org.apache.zookeeper.server.persistence.FileTxnSnapLog.restore(FileTxnSnapLog.java:204)
        at org.apache.zookeeper.server.ZKDatabase.loadDataBase(ZKDatabase.java:223)
        at org.apache.zookeeper.server.quorum.QuorumPeer.loadDataBase(QuorumPeer.java:530)
        at org.apache.zookeeper.server.quorum.QuorumPeer.start(QuorumPeer.java:520)
        at org.apache.zookeeper.server.quorum.QuorumPeerMain.runFromConfig(QuorumPeerMain.java:167)
        at org.apache.zookeeper.server.quorum.QuorumPeerMain.initializeAndRun(QuorumPeerMain.java:116)
        at org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.java:79)
2018-06-25 17:18:47,212 ERROR org.apache.zookeeper.server.quorum.QuorumPeerMain: Unexpected exception, exiting abnormally
java.lang.RuntimeException: Unable to run quorum server 
        at org.apache.zookeeper.server.quorum.QuorumPeer.loadDataBase(QuorumPeer.java:578)
        at org.apache.zookeeper.server.quorum.QuorumPeer.start(QuorumPeer.java:520)
        at org.apache.zookeeper.server.quorum.QuorumPeerMain.runFromConfig(QuorumPeerMain.java:167)
        at org.apache.zookeeper.server.quorum.QuorumPeerMain.initializeAndRun(QuorumPeerMain.java:116)
        at org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.java:79)
Caused by: java.io.EOFException
        at java.io.DataInputStream.readInt(DataInputStream.java:392)
        at org.apache.jute.BinaryInputArchive.readInt(BinaryInputArchive.java:63)
        at org.apache.zookeeper.server.persistence.FileHeader.deserialize(FileHeader.java:64)
        at org.apache.zookeeper.server.persistence.FileTxnLog$FileTxnIterator.inStreamCreated(FileTxnLog.java:594)
        at org.apache.zookeeper.server.persistence.FileTxnLog$FileTxnIterator.createInputArchive(FileTxnLog.java:613)
        at org.apache.zookeeper.server.persistence.FileTxnLog$FileTxnIterator.goToNextLog(FileTxnLog.java:579)
        at org.apache.zookeeper.server.persistence.FileTxnLog$FileTxnIterator.next(FileTxnLog.java:661)
        at org.apache.zookeeper.server.persistence.FileTxnSnapLog.restore(FileTxnSnapLog.java:204)
        at org.apache.zookeeper.server.ZKDatabase.loadDataBase(ZKDatabase.java:223)
        at org.apache.zookeeper.server.quorum.QuorumPeer.loadDataBase(QuorumPeer.java:530)
        ... 4 more

解决办法:

# 清空datadir下的version-2
$ cat /etc/zookeeper/conf.dist/zoo.cfg | grep datadir
datadir=/var/lib/zookeeper 
$ cd /var/lib/zookeeper 
$ ls 
myid version-2
$ cp -r version-2 version-2_bak
$ rm -rf version-2/*

# 重启
$ zkServer.sh  start 

 

© 著作权归作者所有

共有 人打赏支持
刀锋
粉丝 2
博文 396
码字总数 300958
作品 0
济南
程序员
Unable to load NLS charset,U盘挂载不了,USB挂载时提示“No Such Device”,mount: Mounting /dev/sda1 on /mnt failed: No such device

其实这是内核配置问题,主要是文件系统不全,当然,USB驱动和Mass storage/SCSI disk/VFat支持要选上,如果还不行,请参考如下: 1、提示 Unable to load NLS charset cp437 FAT: codepage c...

长平狐
2012/06/12
2.1K
0
android是用外部sqlite文件问题求解.

有一个10m多大小的sqlite文件,要在android应用中使用它。 尝试过的方法如下: 1、把sqlite文件放入raw目录下,通过文件读写操作,将sqlite文件存入到sd卡中。这时候会出现错误:android.dat...

苏谷子
2013/06/21
1K
2
ORACLE使用RMAN对SYSTEM表空间进行介质恢复

注意:数据库应该支持在归档模式。 1.对SYSTEMG表空间做一个备份 [oracle@bys001 ~]$ rman target / Recovery Manager: Release 11.2.0.1.0 - Production on Tue Sep 17 10:42:18 2013 Copyr......

长平狐
2013/09/17
46
0
生产系统RMAN备份失败ORA-00245

一、环境描述 AIX 6.1 Oracle 11.2.0.3 三节点RAC 二、问题描述 1.全库备份出错 Starting Control File and SPFILE Autobackup at 04-NOV-2017 10:54:04 released channel: d1 released chan......

roidba
2017/11/04
0
0
Linux环境下oracle数据库Rman备份异机恢复

备份的数据库和要恢复的数据库OS和数据库的版本均一致,恢复的目录也均一致!备份数据库:RMAN> backup format ‘/home/oracle/scripts/full_prod.%U’ database plus archivelog;备份控制文...

wuhui66
01/08
0
0

没有更多内容

加载失败,请刷新页面

加载更多

Flask 开发填坑

插件的选择: flask-security 真的是个鸡肋啊。自带的页面,好丑。还不如用flask-login来做呢。

pearma
14分钟前
0
0
讲述下 :LVM逻辑卷管理遇到的问题

LVM学习逻辑卷管理创建逻辑卷遇到的问题 1 实验环境 系统 内核 发行版本 CentOS 2.6.32-754.2.1.el6.x86_64 CentOS release 6.10 (Final) 由于是最小化安装没有xfs命令,yum安装如下包支持此...

linuxprobe16
50分钟前
0
0
day95-20180922-英语流利阅读-待学习

Hey Jude 半个世纪传唱不衰的背后故事 毛西 2018-09-22 1.今日导读 2004 年,The Beatles 被《滚石》杂志选为“历史上最伟大的 50 位流行音乐家的第一位”。这四名来自英国利物浦的男孩不仅对...

飞鱼说编程
57分钟前
1
0
OSChina 周六乱弹 —— 放假前期焦虑症晚期

Osc乱弹歌单(2018)请戳(这里) 【今日歌曲】 @andonny :分享Matteo的单曲《Panama》: 《Panama》- Matteo 手机党少年们想听歌,请使劲儿戳(这里) @新垣吉衣OSC :我发现只要去有小朋友...

小小编辑
今天
193
10
wait()被notify()后,接着执行wait()后面的语句

wait()被notify()后,接着执行wait()后面的语句

noteman
今天
1
0

没有更多内容

加载失败,请刷新页面

加载更多

返回顶部
顶部