Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Adding nodes to Cassandra Cluster

I have a 1 node - 1 cluster Cassandra running on my local machine. I want to see how Cassandra scales up, when I simply add the second node to the same cluster. The second node that I am adding will also run from my local machine.

I have been trying to lookup a lot of approaches to do this, but can't find any. Any simple way through which I can add second instance of Cassandra to my cluster?

like image 685
ATP Avatar asked Nov 04 '15 01:11

ATP


1 Answers

The act of adding a second node is known as bootstrapping. The procedure is straightforward:

  • Make sure the cluster names match in cassandra.yaml

  • Point the new (joining) node to the cluster using the seeds setting in the yaml

  • Start cassandra, it will join.

This is described in detail online, but one of the easiest ways to see it in action is using ccm , which is a tool many cassandra developers use to setup fake clusters on their local computers.

Currently (all versions up to 3.9), Cassandra's unique ID is an IP - you can only have one instance per IP. If you need more than one cassandra instance per computer, you need to use multiple IPs.

like image 88
Jeff Jirsa Avatar answered Nov 15 '22 11:11

Jeff Jirsa