Cassandra cqlsh无法连接到任何服务器 - 127.0.0.1:9160(关闭)>已经关闭 [英] Cassandra cqlsh Unable to connect to any servers - 127.0.0.1:9160 (closed)> is already closed
问题描述
我在OSX上安装了Cassandra。
当尝试从/ bin /运行cqlsh时,会出现以下错误:
I installed Cassandra on OSX. When trying to run cqlsh from /bin/, I get the following error:
> Connection error: ('Unable to connect to any servers', {'127.0.0.1':
> ConnectionShutdown('Connection <AsyncoreConnection(4522252560)
> 127.0.0.1:9160 (closed)> is already closed',)})
我安装Cassandra时遇到了问题, cassandra,从datastax安装了DSE,并从Apache下载了一个二进制文件。
I had difficulty installing Cassandra, and had used brew install cassandra, installed DSE from datastax, and downloaded a binary from Apache.
推荐答案
未正确卸载的安装。我的用户 .cassandra
目录有一些默认配置,必须是一个不同的版本,并阻止cqlsh启动。
I think the issue was the result of having a previous installation that wasn't properly uninstalled. My user .cassandra
directory had some default configs, that must have been for a different version, and prevented cqlsh from starting.
rm -Rf ~/.cassandra
,我可以正确运行cqlsh。
After that, I could run cqlsh properly.
$ bin/cqlsh
Connected to Test Cluster at 127.0.0.1:9042.
[cqlsh 5.0.1 | Cassandra 2.1.2 | CQL spec 3.2.0 | Native protocol v3]
Use HELP for help.
cqlsh>
这篇关于Cassandra cqlsh无法连接到任何服务器 - 127.0.0.1:9160(关闭)>已经关闭的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!