CQLSH“无法连接到任何服务器”在Windows安装上
我在Windows 10上安装了Cassandra。当我尝试从 /bin /运行CQLSH时,
我会收到以下错误:
Connection error: ('Unable to connect to any servers', {'127.0.0.1': \
error(10061, "Tried connecting to [('127.0.0.1', 9042)].
Last error: No connection could be made because the target machine \
actively refused it")})
我从Apache.org官方网站安装了Cassandra。我也从 https://phoenixnap.com/kb/kb/install-install-install-install-on-windows - 从参考中,一切看起来都不错。
谁能帮我解决这个问题?提前致谢。
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
该错误指出
cqlsh
无法连接到本地Cassandra实例。conf/cassandra.yaml
中的默认配置是让卡桑德拉在localhost
(127.0.0.0.1
)上聆听CQL客户端> 9042 :由于您遇到了“连接拒绝”错误,因此最有可能的问题是Cassandra在Windows机器上没有运行。检查Cassandra日志(通常在
logs/system.log
中)中的错误,以提供有关Cassandra为什么无法启动的线索。附带说明,Cassandra 3.x的Windows支持非常有限,并且由于操作系统的限制,有几个已知问题无法解决。
此外,由于缺乏维护者和测试,Cassandra 4.0已完全放弃了Windows的支撑()。
作为解决方法,我们建议以下内容:
之 类的软件。 astra db 有一个免费的层,可让您单击几次无需信用卡就可以单击几次启动Cassandra群集。干杯!
The error states that
cqlsh
can't connect to the local Cassandra instance. The default configuration inconf/cassandra.yaml
is for Cassandra to listen for CQL clients onlocalhost
(127.0.0.1
) and CQL port9042
:Since you're getting a "connection refused" error, the most likely issue is that Cassandra is not running on your Windows machine. Check the Cassandra logs (usually in
logs/system.log
) for errors which would provide clues as to why Cassandra couldn't start.As a side note, there is very limited Windows support in Cassandra 3.x and there are several known issues that will not be fixed due to limitations in the operating system.
Furthermore, Windows support has been completely dropped in Cassandra 4.0 due to lack of maintainers and testing (CASSANDRA-16171).
As a workaround, we recommend the following:
If you just want to build apps with Cassandra as a backend, Astra DB has a free tier that lets you launch a Cassandra cluster in a few clicks with no credit card required. Cheers!
您是否在试图连接时保持此终端打开并运行Cassandra?请注意,您必须从其他终端窗口启动
cqlsh
。请再次检查步骤,大部分可能根本不运行。特别关注P.4。
Do you keep this terminal open and Cassandra runs when you are trying to connect? Notice you have to launch
cqlsh
from a different terminal window.Please check the steps again, mostly probably Cassandra simply doesn't run. Keep attention on the p.4 specially.