本文介绍了使用 Amazon Elastic IP 的 Cassandra Datastax Enterprise的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想不使用节点私有 IP 地址而是使用弹性公共 IP 在 Amazon EC2 实例上运行 Cassandra Datastax Enterprise

I would like to run Cassandra Datastax Enterprise on Amazon EC2 instances using not the node private IP address but Elastic Public IPs

我当前的配置如下:

/etc/dse/cassandra/cassandra.yaml

seed_provider:
  - class_name: org.apache.cassandra.locator.SimpleSeedProvider
    parameters:
        seeds: "publicIP"

listen_address:  "publicIP"
endpoint_snitch:Ec2Snitch
rpc_address: "publicIP"

dse"服务未正常启动.

The "dse" service is not starting properly.

/var/log/cassandra/system.log 显示以下错误:

/var/log/cassandra/system.log is showing the following error:

org.apache.cassandra.exceptions.ConfigurationException:无法绑定到地址/:7000.将 cassandra.yaml 中的 listen_address 设置为您可以绑定的接口,例如您在 EC2 上的私有 IP 地址

我也尝试将广播地址更改为指向公共 IP 地址,但它不起作用.

I have also tried to change the broadcast_address to point to the public IP address but it doesn't work.

有没有办法以使用弹性 IP 地址而不是 EC2 机器的私有 IP 的方式运行 dse 服务 (Cassandra)?

Is there any way of running dse service (Cassandra) in a way it uses the elastic IP addresses and not the private IPs of EC2 boxes?

推荐答案

这里不是一个新问题,而是查看您的配置,进行这些更改.

Not a new question here, but looking at your config, make these changes.

listen_address: private_ip
broadcast_address: public_ip
rpc_address: 0.0.0.0

种子应该是 public_ip 这样你就可以了.

Seeds should be public_ip so you're ok there.

这篇关于使用 Amazon Elastic IP 的 Cassandra Datastax Enterprise的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-29 11:11