gpt4 book ai didi

authentication - zookeeper sasl身份验证问题

转载 作者:行者123 更新时间:2023-12-03 17:37:34 24 4
gpt4 key购买 nike

我正在尝试为我的 Kafka 动物园管理员设置 SASL 身份验证。我按照以下链接中提到的所有步骤进行操作

https://cwiki.apache.org/confluence/display/ZOOKEEPER/Client-Server+mutual+authentication

下面是我保存在/home 目录中的 server_jaas.conf 文件

Server {
org.apache.kafka.common.security.plain.PlainLoginModule required
username="admin"
password="admin-secret"
user_admin="admin-secret"
};

下面是我的 java.env 文件配置
SERVER_JVMFLAGS="-Djava.security.auth.login.config=/home/server_jaas.conf"

下面是我得到的错误
2017-08-01 16:49:40,774 [myid:] - ERROR [main:ServerCnxnFactory@199] - No JAAS configuration section named 'Server' was foundin '/home/server_jaas.conf'.
2017-08-01 16:49:40,774 [myid:] - ERROR [main:ZooKeeperServerMain@64] - Unexpectked exception, exiting abnormally
java.io.IOException: No JAAS configuration section named 'Server' was foundin '/home/server_jaas.conf'.
at org.apache.zookeeper.server.ServerCnxnFactory.configureSaslLogin(ServerCnxnFactory.java:200)
at org.apache.zookeeper.server.NIOServerCnxnFactory.configure(NIOServerCnxnFactory.java:82)
at org.apache.zookeeper.server.ZooKeeperServerMain.runFromConfig(ZooKeeperServerMain.java:117)
at org.apache.zookeeper.server.ZooKeeperServerMain.initializeAndRun(ZooKeeperServerMain.java:87)
at org.apache.zookeeper.server.ZooKeeperServerMain.main(ZooKeeperServerMain.java:53)
at org.apache.zookeeper.server.quorum.QuorumPeerMain.initializeAndRun(QuorumPeerMain.java:116)
at org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.java:78)

最佳答案

尝试添加;到服务器定义的末尾

Server {
org.apache.kafka.common.security.plain.PlainLoginModule required
username="admin"
password="admin-secret"
user_admin="admin-secret";
};

关于authentication - zookeeper sasl身份验证问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45441433/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com