从apache cassandra 3.11.4迁移到4.0测试版时出现问题

rqqzpn5f  于 2021-06-13  发布在  Cassandra
关注(0)|答案(1)|浏览(549)

在我的开发系统中,当cassandra从3.11.4迁移到4.0测试版时,我面临一个问题。

ERROR [main] 2020-07-31 15:34:36,099 CassandraDaemon.java:800 - Exception encountered during startup
java.lang.IllegalArgumentException: Compact Tables are not allowed in Cassandra starting with 4.0 version. Use `ALTER ... DROP COMPACT STORAGE` command supplied in 3.x/3.11 Cassandra in order to migrate off Compact Storage.
        at org.apache.cassandra.schema.SchemaKeyspace.fetchTable(SchemaKeyspace.java:960)
        at org.apache.cassandra.schema.SchemaKeyspace.fetchTables(SchemaKeyspace.java:919)
        at org.apache.cassandra.schema.SchemaKeyspace.fetchKeyspace(SchemaKeyspace.java:878)
        at org.apache.cassandra.schema.SchemaKeyspace.fetchKeyspacesWithout(SchemaKeyspace.java:869)
        at org.apache.cassandra.schema.SchemaKeyspace.fetchNonSystemKeyspaces(SchemaKeyspace.java:857)
        at org.apache.cassandra.schema.Schema.loadFromDisk(Schema.java:102)
        at org.apache.cassandra.schema.Schema.loadFromDisk(Schema.java:91)
        at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:241)
        at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:661)
        at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:778)

错误表示要删除压缩存储,但在我的数据库中没有启用压缩存储的表。请提出任何解决方案!!

mbyulnm0

mbyulnm01#

例外情况表明,您有一个或多个表仍在使用不推荐的thrift存储格式,即使您不知道这种格式。
请尝试以下(粗略和简单)命令:

$ cqlsh <node_ip> -e "DESCRIBE FULL SCHEMA" | egrep "CREATE TABLE|COMPACT STORAGE"

这将列出集群中的所有表,并指示其中是否仍有压缩存储支持。如果启用了身份验证,则需要相应地修改它以包含db凭据。干杯!

相关问题