Apache Cassandra - cqlsh 操作超时

Apache Cassandra - cqlsh operation timeout

我正在尝试启动 cqlsh,这是我得到的结果:

/bin$ ./cqlsh
Connection error: ('Unable to connect to any servers', {'127.0.0.1': 
    OperationTimedOut('errors=None, last_host=None',)})

我尝试删除 ~/.cassandra,但没有用。我还将 cassandra.yaml 与有效的版本进行了比较。

有什么想法吗?

根据您的版本和配置,检查 cassandra.yaml 中为 listen_address and/or rpc_address 指定的值。如果它们被定义为 localhost 以外的任何内容,您将需要在与 cqlsh 连接时提供该地址。

$ grep listen_address: /etc/cassandra/cassandra.yaml
listen_address: 210.156.89.15

$ cqlsh 210.156.89.15 -u aploetz -p aploetz 
Connected to PermanentWaves at 210.156.89.15.
[cqlsh 5.0.1 | Cassandra 2.1.4 | CQL spec 3.2.0 | Native protocol v3]
Use HELP for help.
aploetz@cqlsh>

在这个旧线程上发帖作为其他人的备忘录,因为到目前为止我无法找到任何信息来解决这些症状而不进行调试:

在缓慢的测试集群中遇到了同样的问题,我通过在 cqlsh.py 文件的 Cluster() init 中设置缺失的 control_connection_timeout kwargs 解决了这个问题。

已打开问题并在 https://issues.apache.org/jira/browse/CASSANDRA-10959

提供补丁建议