返回到文章

采纳

编辑于

关于KAFKA10.0.1使用SASL_PLAINTEXT遇到的问题

kafka

配置完SASL就无法生成和消费了。消费的时候报,请问是我哪里配置错了么?困扰了好几天,感谢解答。

kafka.common.BrokerEndPointNotAvailableException: End point with security protocol PLAINTEXT not found for broker 0

配置如下:

server.xml
listeners=SASL_PLAINTEXT://fjrd01:9092
security.inter.broker.protocol=SASL_PLAINTEXT
sasl.mechanism.inter.broker.protocol=PLAIN
sasl.enabled.mechanisms=PLAIN
authorizer.class.name=kafka.security.auth.SimpleAclAuthorizer
super.users=User:admin
kafka_server_jaas.conf
KafkaServer {
    org.apache.kafka.common.security.plain.PlainLoginModule required
    username="admin"
    password="admin"
    user_admin="admin"
    user_alice="alice";
};
kafka_client_jaas.conf
KafkaClient {
  org.apache.kafka.common.security.plain.PlainLoginModule required
  username="alice"
  password="alice";
};