How can the seemingly odd behavior in Cassandra cluster be explained?
Asked Answered
I

1

0

I created an Apache Cassandra 2.1.2 cluster of 50 nodes. I named the cluster as "Test Cluster", the default. Then for some testing, I separated one node out of the 50 node cluster. I shut down Cassandra, deleted data dirs, flushed nodetool. Then I edited the single node cluster and called it as "Single Node Test Cluster" I edited seeds, cluster_name and listen_address fields appropriately. I also setup JMX correctly. Now here is what happens. 1. When I run nodetool status on the single node, I see only one node as up and running. If I run nodetool describecluster, I see the new cluster name - "Single Node Test Cluster" 2. When I run nodetool commands on one of the 49 nodes, I see total 50 nodes with the single node as down and I see cluster name as "Test Cluster" 3. There are datastax-agents installed on each node and I had also setup OpsCenter to monitor the cluster. In OpsCenter, I still see 50 nodes as up and cluster name as "Test Cluster" So my question is why I am seeing these 3 different depictions of same topology and is this expected?

Another issue is, when I start Cassandra on the single node, I still see that it somehow tries to communicate with other nodes and I keep getting cluster name mismatch (Test Cluster != Single Node Test Cluster) WARN on the console before the single node cluster starts.

Is this as expected or is this is bug in Cassandra?

Immateriality answered 28/3, 2015 at 2:22 Comment(0)
D
3

Yes if you remove a node from your cluster you need to inform the restore of the cluster that it is gone.

You do that by decommissioning the node when its still in the cluster or by saying nodetool remove node from another node when the node is gone. I.E. you no longer have access to the box.

If you do neither of the above, you'll still see the node in the other's system.peers table.

Deuno answered 28/3, 2015 at 3:38 Comment(1)
Thanks. made perfect sense and I was able to verify as well.Immateriality

© 2022 - 2024 — McMap. All rights reserved.