简体   繁体   中英

Nodes connection problem for Cassandra in AWS

Hi I'm creating a cluster in AWS to run Cassandra. So far I have created 3 Ec2 instances in the same region but in three different availability zones.

I modified the .yaml in this way:

  • For Ec2-1 : seeds: Ec2-2 private_ip, listen_address: Ec2-2 private_ip, broadcast_rpc_address: Ec2-2 private_ip (with rpc_address: 0.0.0.0)
  • For Ec2-2 and Ec2-3 similarly I used the private_ip of Ec2-3 and Ec2-1 respectively.

Finally I put all these three instances in the same security group but actually cassandra does not work.

The error in the log file for Ec2-1 is:

org.apache.cassandra.exceptions.ConfigurationException: Unable to bind to address /172.31.15.109:7000.

(where 172.31.15.109 is the Ec2-2 private_ip).

This seems to be a problem related with the communication between the nodes but i don't understand why they can't communicate (with a single ping or a telnet using port 22 they sees each other).

Those are the rule I added in the security group both in inbound and outbound: i also added the rule all traffic but nothing change.

安全组规则

Your configuration seems to be wrong.

Refer the link http://cassandra.apache.org/doc/latest/configuration/cassandra_config_file.html

The listen_address and rpc_address of a node should IP of the node itself not other node's IP.

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