<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question zookeeper server + Unable to load database on disk in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283400#M210639</link>
    <description>&lt;P&gt;We have kafka cluster with 3 nodes , each kafka include zookeeper server and schema registry&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;We get the following error on one of the zookeeper server&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;[2019-11-12 07:44:20,719] ERROR Unable to load database on disk (org.apache.zookeeper.server.quorum.QuorumPeer)&lt;BR /&gt;java.io.IOException: Unreasonable length = 198238896&lt;BR /&gt;at org.apache.jute.BinaryInputArchive.checkLength(BinaryInputArchive.java:127)&lt;BR /&gt;at org.apache.jute.BinaryInputArchive.readBuffer(BinaryInputArchive.java:92)&lt;BR /&gt;at org.apache.zookeeper.server.persistence.Util.readTxnBytes(Util.java:233)&lt;BR /&gt;at org.apache.zookeeper.server.persistence.FileTxnLog$FileTxnIterator.next(FileTxnLog.java:629)&lt;BR /&gt;at org.apache.zookeeper.server.persistence.FileTxnSnapLog.restore(FileTxnSnapLog.java:166)&lt;BR /&gt;at org.apache.zookeeper.server.ZKDatabase.loadDataBase(ZKDatabase.java:223)&lt;BR /&gt;at org.apache.zookeeper.server.quorum.QuorumPeer.loadDataBase(QuorumPeer.java:601)&lt;BR /&gt;at org.apache.zookeeper.server.quorum.QuorumPeer.start(QuorumPeer.java:591)&lt;BR /&gt;at org.apache.zookeeper.server.quorum.QuorumPeerMain.runFromConfig(QuorumPeerMain.java:164)&lt;BR /&gt;at org.apache.zookeeper.server.quorum.QuorumPeerMain.initializeAndRun(QuorumPeerMain.java:111)&lt;BR /&gt;at org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.java:78)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;seems that some snapshot files under folder /opt/confluent/zookeeper/data/version-2 are corrupted&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;under folder version-2 , we have the following example files&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;many files as log.3000667b5&lt;BR /&gt;many files as snapshot.200014247&lt;BR /&gt;one file - acceptedEpoch&lt;BR /&gt;one file – currentEpoch&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;so the question is – how to start the zookeeper server&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;from my understanding we have two options , but not sure about them&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;one option is to move version-2 folder to other place as version-2_backup&amp;nbsp;&lt;BR /&gt;and create new folder - version-2 under /opt/confluent/zookeeper/data&lt;BR /&gt;then start the zookeeper server and hope that snapshot will copied from other good active zookeeper server ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;second option is maybe to move version-2 folder to other place as version-2_backup , create new folder as - version-2&lt;BR /&gt;and copy all content from version-2 from good machine to the bad zookeeper server to version-2 , but I not sure if this is right option?&lt;/P&gt;</description>
    <pubDate>Wed, 20 Nov 2019 05:38:45 GMT</pubDate>
    <dc:creator>mike_bronson7</dc:creator>
    <dc:date>2019-11-20T05:38:45Z</dc:date>
    <item>
      <title>zookeeper server + Unable to load database on disk</title>
      <link>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283400#M210639</link>
      <description>&lt;P&gt;We have kafka cluster with 3 nodes , each kafka include zookeeper server and schema registry&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;We get the following error on one of the zookeeper server&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;[2019-11-12 07:44:20,719] ERROR Unable to load database on disk (org.apache.zookeeper.server.quorum.QuorumPeer)&lt;BR /&gt;java.io.IOException: Unreasonable length = 198238896&lt;BR /&gt;at org.apache.jute.BinaryInputArchive.checkLength(BinaryInputArchive.java:127)&lt;BR /&gt;at org.apache.jute.BinaryInputArchive.readBuffer(BinaryInputArchive.java:92)&lt;BR /&gt;at org.apache.zookeeper.server.persistence.Util.readTxnBytes(Util.java:233)&lt;BR /&gt;at org.apache.zookeeper.server.persistence.FileTxnLog$FileTxnIterator.next(FileTxnLog.java:629)&lt;BR /&gt;at org.apache.zookeeper.server.persistence.FileTxnSnapLog.restore(FileTxnSnapLog.java:166)&lt;BR /&gt;at org.apache.zookeeper.server.ZKDatabase.loadDataBase(ZKDatabase.java:223)&lt;BR /&gt;at org.apache.zookeeper.server.quorum.QuorumPeer.loadDataBase(QuorumPeer.java:601)&lt;BR /&gt;at org.apache.zookeeper.server.quorum.QuorumPeer.start(QuorumPeer.java:591)&lt;BR /&gt;at org.apache.zookeeper.server.quorum.QuorumPeerMain.runFromConfig(QuorumPeerMain.java:164)&lt;BR /&gt;at org.apache.zookeeper.server.quorum.QuorumPeerMain.initializeAndRun(QuorumPeerMain.java:111)&lt;BR /&gt;at org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.java:78)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;seems that some snapshot files under folder /opt/confluent/zookeeper/data/version-2 are corrupted&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;under folder version-2 , we have the following example files&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;many files as log.3000667b5&lt;BR /&gt;many files as snapshot.200014247&lt;BR /&gt;one file - acceptedEpoch&lt;BR /&gt;one file – currentEpoch&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;so the question is – how to start the zookeeper server&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;from my understanding we have two options , but not sure about them&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;one option is to move version-2 folder to other place as version-2_backup&amp;nbsp;&lt;BR /&gt;and create new folder - version-2 under /opt/confluent/zookeeper/data&lt;BR /&gt;then start the zookeeper server and hope that snapshot will copied from other good active zookeeper server ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;second option is maybe to move version-2 folder to other place as version-2_backup , create new folder as - version-2&lt;BR /&gt;and copy all content from version-2 from good machine to the bad zookeeper server to version-2 , but I not sure if this is right option?&lt;/P&gt;</description>
      <pubDate>Wed, 20 Nov 2019 05:38:45 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283400#M210639</guid>
      <dc:creator>mike_bronson7</dc:creator>
      <dc:date>2019-11-20T05:38:45Z</dc:date>
    </item>
    <item>
      <title>Re: zookeeper server + Unable to load database on disk</title>
      <link>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283404#M210643</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/59349"&gt;@mike_bronson7&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes&amp;nbsp;"Unable to load database on disk" is due to corruption&amp;nbsp; also as a backup r&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;# mv&amp;nbsp;/opt/confluent/zookeeper/data/version-2&amp;nbsp; &amp;nbsp;/tmp&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Then restart the zookeeper it should copy&amp;nbsp; the snapshot from one of the healthy nodes in the quorum&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;HTH&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2019 19:21:08 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283404#M210643</guid>
      <dc:creator>Shelton</dc:creator>
      <dc:date>2019-11-19T19:21:08Z</dc:date>
    </item>
    <item>
      <title>Re: zookeeper server + Unable to load database on disk</title>
      <link>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283406#M210645</link>
      <description>&lt;P&gt;thank you , any risks with that option?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;do we need also to create empty folder - version-2 ? under&amp;nbsp;&lt;STRONG&gt;&amp;nbsp;/opt/confluent/zookeeper/data/&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2019 19:24:03 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283406#M210645</guid>
      <dc:creator>mike_bronson7</dc:creator>
      <dc:date>2019-11-19T19:24:03Z</dc:date>
    </item>
    <item>
      <title>Re: zookeeper server + Unable to load database on disk</title>
      <link>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283409#M210648</link>
      <description>&lt;P&gt;Dear Shelton&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;do we need also to create empty folder - &lt;STRONG&gt;version-2&lt;/STRONG&gt; ? under&amp;nbsp;&lt;/SPAN&gt;/opt/confluent/zookeeper/data&lt;/P&gt;&lt;P&gt;after we moved the original folder -&amp;nbsp;version-2&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2019 19:53:54 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283409#M210648</guid>
      <dc:creator>mike_bronson7</dc:creator>
      <dc:date>2019-11-19T19:53:54Z</dc:date>
    </item>
    <item>
      <title>Re: zookeeper server + Unable to load database on disk</title>
      <link>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283414#M210652</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/59349"&gt;@mike_bronson7&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes, in fact, a better solution is &lt;STRONG&gt;mv&lt;/STRONG&gt; all the contents of&amp;nbsp;&lt;STRONG&gt;&amp;nbsp;/opt/confluent/zookeeper/data/version-2&amp;nbsp; &amp;nbsp;&lt;/STRONG&gt;usually ie [&lt;STRONG&gt;log.1,log.18263] &lt;/STRONG&gt;there could be many that's why its easier to move&amp;nbsp; than delete but remember to recreate the &lt;STRONG&gt;version-2&lt;/STRONG&gt; directory with the same &lt;STRONG&gt;user: group&lt;/STRONG&gt; and&lt;STRONG&gt; permissions&amp;nbsp; &lt;/STRONG&gt;take note of those details &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;HTH&amp;nbsp;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2019 20:22:08 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283414#M210652</guid>
      <dc:creator>Shelton</dc:creator>
      <dc:date>2019-11-19T20:22:08Z</dc:date>
    </item>
    <item>
      <title>Re: zookeeper server + Unable to load database on disk</title>
      <link>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283415#M210653</link>
      <description>&lt;P&gt;I prefer to move the folder - version-2&amp;nbsp;&lt;/P&gt;&lt;P&gt;and create it again with all permissions&amp;nbsp;&amp;nbsp;&lt;STRONG&gt;user: group&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2019 20:30:56 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283415#M210653</guid>
      <dc:creator>mike_bronson7</dc:creator>
      <dc:date>2019-11-19T20:30:56Z</dc:date>
    </item>
    <item>
      <title>Re: zookeeper server + Unable to load database on disk</title>
      <link>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283420#M210658</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/59349"&gt;@mike_bronson7&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is a good compromise hoping you have enough&amp;nbsp; disk space&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;change directory&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF6600"&gt;# cd&amp;nbsp;&lt;SPAN&gt;/opt/confluent/zookeeper/data&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Move the directory&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF6600"&gt;&lt;SPAN&gt;# mv version-2&lt;/SPAN&gt;&amp;nbsp;&amp;nbsp;&lt;SPAN&gt;version-2_bck&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Recreate with same permissions&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF6600"&gt;# mkdir&amp;nbsp;version-2&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF6600"&gt;# chown user:group&amp;nbsp;&amp;nbsp;version-2&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Compare the permissions&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF6600"&gt;&lt;SPAN&gt;# ls -al&amp;nbsp;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF6600"&gt;&lt;SPAN&gt;version-2&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF6600"&gt;&lt;SPAN&gt;version-2_bck&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Now you can restart zookeeper&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2019 20:57:36 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283420#M210658</guid>
      <dc:creator>Shelton</dc:creator>
      <dc:date>2019-11-19T20:57:36Z</dc:date>
    </item>
    <item>
      <title>Re: zookeeper server + Unable to load database on disk</title>
      <link>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283421#M210659</link>
      <description>&lt;P&gt;thank you so much&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;btw - can I get your advice about other thread -&amp;nbsp;&lt;A href="https://community.cloudera.com/t5/Support-Questions/schema-registry-service-failed-to-start-due-schemas-topic/td-p/283403" target="_blank"&gt;https://community.cloudera.com/t5/Support-Questions/schema-registry-service-failed-to-start-due-schemas-topic/td-p/283403&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Nov 2019 21:09:09 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/zookeeper-server-Unable-to-load-database-on-disk/m-p/283421#M210659</guid>
      <dc:creator>mike_bronson7</dc:creator>
      <dc:date>2019-11-19T21:09:09Z</dc:date>
    </item>
  </channel>
</rss>

