【问题标题】:After setting authenticator: PasswordAuthenticator in Cassandra.yaml, Cassandra CQL Shell does not run在 Cassandra.yaml 中设置验证器:PasswordAuthenticator 后,Cassandra CQL Shell 不运行
【发布时间】:2015-01-21 04:28:08
【问题描述】:

我是 Cassandra 的新手。我正在使用 Datastax 社区版并且在 Windows 7 中仅使用一个节点。尝试更改我的身份验证,在 Cassandra.yaml 中将身份验证器值从 AllowAllAuthenticator 设置为 PasswordAuthenticator。在该设置之后,它不允许我运行我的 Cassandra CQL Shell。

第一季度。为什么会这样?

第二季度。如何克服?

【问题讨论】:

    标签: windows cassandra cqlsh


    【解决方案1】:

    您是如何访问 cqlsh 的?如果您激活了密码验证器,那么您需要使用用户名和密码标志指定默认的 Cassandra 超级用户。

    Linux:

    ./cqlsh -u cassandra -p cassandra
    

    在 Windows 中,我猜是这样的:

    cqlsh -u cassandra -p cassandra
    

    请注意,进入后,您需要创建自己的超级用户和disable the default cassandra account, as described here

    “我正在从 START-> Datastax Community Edition-> Cassandra CQL Shell 访问 cqlsh”

    我不知道 Windows 版本现在有 cqlsh 的快捷方式。尝试修改该快捷方式的目标 (as shown here),并将 -u cassandra -p cassandra 添加到末尾。我可以通过安装快捷方式的“目标”属性并将其修改为此:

    "E:\Program Files\DataStax Community\python\python.exe" "e:\Program Files\DataStax Community\apache-cassandra\bin\cqlsh" -u cassandra -p cassandra
    

    基本上,将-u-p 标志放在双引号之外,它应该可以工作。

    【讨论】:

    • 我正在从 START-> Datastax Community Edition-> Cassandra CQL Shell 访问 cqlsh
    • 我按照您的建议进行了更改,但 CQL shell 仍然无法正常工作。
    • 更改前-目标:"C:\Program Files\DataStax Community\python\python.exe" "C:\Program Files\DataStax Community\apache-cassandra\bin\cqlsh" 更改后-目标:“C:\Program Files\DataStax Community\python\python.exe”“C:\Program Files\DataStax Community\apache-cassandra\bin\cqlsh -u cassandra -p cassandra”
    • 我还尝试从安装的文件夹中运行“cqlsh”批处理文件。同样的事情也会发生。窗口只是闪烁一条消息“连接错误:错误请求:您尚未登录”
    • @AvijoyChakma 太好了,很高兴我能帮上忙。你介意“接受”这个答案吗?谢谢。
    猜你喜欢
    • 2014-12-16
    • 1970-01-01
    • 2023-03-06
    • 2016-10-16
    • 2023-03-29
    • 2017-02-15
    • 1970-01-01
    • 2017-06-05
    • 1970-01-01
    相关资源
    最近更新 更多