1
votes

I have a Datastax cluster cassandra (1.2) on EC2 with opCenter (3.0.1) with 2 nodes. I followed this guide : http://www.datastax.com/docs/1.2/install/install_ami

using this :

--clustername cass1 --totalnodes 2 --version community Using own security group with right opened ports (as guide said)

After that i can open opsCenter and fix the 2 nodes and everything is fine

Then i want to add a new node to the cluster (2 ways to do it)

1 - Via the opsCenter i have : "Install Errored: The installed agent doesn't seem to be responding"

Instance is running but...

2 - Via the guide : http://www.datastax.com/docs/1.2/install/expand_ami

I create another cluster with these parameters

--clustername tmp --totalnodes 1 --version community

(clustername different then the first cluster)

Then on instance :

sudo service cassandra stop

sudo rm -rf /var/lib/cassandra/*

sudo vi /etc/cassandra/cassandra.yaml

 changing cluster name and seed ip

sudo service cassandra start

But when "nodetool status" Failed to connect to '127.0.0.1:7199': Connection refused

Where i'm wrong ? Trying and retrying and i cannot add a node

Thank you :-)

2

2 Answers

1
votes

The AMI installs cassandra in /raid0/cassandra. Instead of removing the data in /var/lib/cassandra, run

sudo rm -rf /raid0/cassandra/*

after stopping the node. That will clear everything out for you and you can change the cluster name in the yaml file and restart it into the correct cluster.

0
votes

I've found a solution

As datastax guide say i have to create a new cluster with a different name than existant cluster then erase the data config data and reconfigure

But sudo rm -rf /var/lib/cassandra/* doesn't erase the cluster name and as i have to change it in the cassandra.yaml when i restart node, it didn't start because name cluster is not the same in .yaml and in system keyspace

So the solution is to create new node with the good cluster name

Maybe there is an other way to change the cluster name....

But i'm keeping the problem of adding new node via opsCenter (more easy way)