I'm trying to run Cassandra in eclipse, but I'm getting this exception
java.lang.IllegalStateException: Unknown commitlog version 4Exception encountered during startup: Unknown commitlog version 4
at org.apache.cassandra.db.commitlog.CommitLogDescriptor.getMessagingVersion(CommitLogDescriptor.java:81)
at org.apache.cassandra.db.commitlog.CommitLogReplayer.recover(CommitLogReplayer.java:118)
at org.apache.cassandra.db.commitlog.CommitLogReplayer.recover(CommitLogReplayer.java:93)
at org.apache.cassandra.db.commitlog.CommitLog.recover(CommitLog.java:146)
at org.apache.cassandra.db.commitlog.CommitLog.recover(CommitLog.java:126)
at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:305)
at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:461)
at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:504)
What am I doing wrong?
Sounds like a version mismatch - possibly from downgrading Cassandra[?]
What version of Cassandra are you using in eclipse? Also, did you have another version running and sharing the same commitlogs? It is likely you have commitlogs from one version of cassandra being read from another. (That was my experience.)
Adding the solution, as provided by @LyubenTodorov in the comments:
To solve this either change your commitlog_directory or empty your current commitlog dir (default is /var/lib/cassandra/commitlog)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With