简体   繁体   中英

Adding new node to Cassandra cluster

I have a 4 node cluster and will be adding an additional node in two days. We aren't using vnodes.

Just wondering the best way to rebalance the cluster after I'm done. Do I just bring the new node up and then start the nodetool move?

Or do I shut each node down, change the initial_token value for each one (using one of those generators to calculate the values for me) and then bring each node up?

I just want to know the simplest way to do this from command line. The new node already has Cassandra installed as it was initially a non-production server, I will delete the data off of the node and change the config files accordingly for the new cluster it will now be a part of, just unsure as to the other steps.

From this page Adding or replacing single-token nodes , the simplest mechanism is to start the new node with it's initial-token left empty in cassandra.yaml. This will make the cluster 'split the token range of the heaviest loaded node and position the new node there'. This won't give you a balanced cluster.

If you want a balanced cluster then you have to go through the nodetool move, node restart, nodetool cleanup procedure you mentioned.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM