从DSE 5.0.9迁移到Apache Cassandra 3.11.3的问题

我们正在考虑从DSE 5.0.9迁移到Apache Cassandra 3.11.3 . 我们已经走得很远并且设法解决了各种问题(包括EverywhereStrategy问题),但是遇到了system.local表的问题 .

到目前为止,迁移/升级仅在一台服务器上完成 . 当我们在这个节点上启动Cassandra 3.11.3时,我们在加载system.local时出错:

INFO [main] 2018-12-07 10:56:12,963 ColumnFamilyStore.java:411 - Initializing system.local
INFO [SSTableBatchOpen:1] 2018-12-07 10:56:12,993 BufferPool.java:230 - Global buffer pool is enabled, when pool is exhausted (max is 512.000MiB) it will allocate on heap
ERROR [SSTableBatchOpen:1] 2018-12-07 10:56:13,013 DebuggableThreadPoolExecutor.java:239 - Error in ThreadPoolExecutor
java.lang.RuntimeException: Unknown column server_id during deserialization
at org.apache.cassandra.db.SerializationHeader$Component.toHeader(SerializationHeader.java:321) ~[apache-cassandra-3.11.3.jar:3.11.3]
at org.apache.cassandra.io.sstable.format.SSTableReader.open(SSTableReader.java:522) ~[apache-cassandra-3.11.3.jar:3.11.3]
at org.apache.cassandra.io.sstable.format.SSTableReader.open(SSTableReader.java:385) ~[apache-cassandra-3.11.3.jar:3.11.3]
at org.apache.cassandra.io.sstable.format.SSTableReader$3.run(SSTableReader.java:570) ~[apache-cassandra-3.11.3.jar:3.11.3]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[na:1.8.0_172]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[na:1.8.0_172]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[na:1.8.0_172]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [na:1.8.0_172]
at org.apache.cassandra.concurrent.NamedThreadFactory.lambda$threadLocalDeallocator$0(NamedThreadFactory.java:81) [apache-cassandra-3.11.3.jar:3.11.3]
at java.lang.Thread.run(Thread.java:748) ~[na:1.8.0_172]

看看我们这里有的另一个Cassandra 3.11.3集群,表中不存在system_id . 但是,它确实在表的DSE 5.0.9版本中 . 如果无法加载system.local,我们最终会收到以下警告:

WARN [main] 2018-12-06 10:43:57,241 SystemKeyspace.java:1087 - No host ID found, created a0bb8c11-2864-4d58-9c0c-59b97b16c48e (Note: This should happen exactly once per node).

(没有主机ID,因为system.local没有加载),这会导致以下错误:

ERROR [main] 2018-12-06 10:43:58,295 CassandraDaemon.java:708 - Exception encountered during startup
java.lang.RuntimeException: A node with address dubdc1-oatjeeramp2dmcassandra-04/10.109.158.254 already exists, cancelling join. Use cassandra.replace_address if you want to replace this node.
at org.apache.cassandra.service.StorageService.checkForEndpointCollision(StorageService.java:558) ~[apache-cassandra-3.11.3.jar:3.11.3]
at org.apache.cassandra.service.StorageService.prepareToJoin(StorageService.java:804) ~[apache-cassandra-3.11.3.jar:3.11.3]
at org.apache.cassandra.service.StorageService.initServer(StorageService.java:664) ~[apache-cassandra-3.11.3.jar:3.11.3]
at org.apache.cassandra.service.StorageService.initServer(StorageService.java:613) ~[apache-cassandra-3.11.3.jar:3.11.3]
at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:379) [apache-cassandra-3.11.3.jar:3.11.3]
at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:602) [apache-cassandra-3.11.3.jar:3.11.3]
at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:691) [apache-cassandra-3.11.3.jar:3.11.3]

此时system.local已被覆盖,并且存储了新的主机ID值,并且Cassandra已关闭 .

-Dcassandra.replace_node=<ip address> 添加到cassandra-env.sh会导致错误,表明该节点已经被引导,因此't be used. I know I can get around this by deleting all of the data, but I really don'不希望这样做 .

恢复system.local的备份将允许我们再次启动DSE . 目前,该节点正在重新运行DSE5.0.9

有没有人见过这个问题,你对如何解决它有什么建议吗?

回答(1)

2 years ago

脚步:

  • 从DSE复制到OSS C *的确切可用配置 .

  • 改变了几个键空间/表:

改变键空间dse_system with replication = {'class':'NetworkTopologyStrategy','DC3':'3'}; // DC1,DC2 = OSS C *

//如果你使用spark alter table cfs_archive.sblocks with compaction = {'class':'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy','max_threshold':'32','min_threshold':'4'} ;

alter table cfs.sblocks with compaction = {'class':'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy','max_threshold':'32','min_threshold':'4'};

  • auto_bootstrap:false JVM_OPTS =“$ JVM_OPTS -Dcassandra.allow_unsafe_replace = true”JVM_OPTS =“$ JVM_OPTS -Dcassandra.replace_address = ...

小心,测试下部环境中的所有内容 . 请点击此链接获取更多信息:https://www.mail-archive.com/user@cassandra.apache.org/msg58077.html