【Kafka问题解决】Connection to xxx could not be established. Broker may not be available.

请检查Kafka的config/server.properties
看看是否有填写

listeners=PLAINTEXT://kafka-host:9092
advertised.listeners=PLAINTEXT://kafka-host:9092

这里的kafka-host需要在/etc/hosts进行映射,服务端映射到本地或内网ip,客户端映射到服务端ip

问题解决。

猜你喜欢

转载自www.cnblogs.com/hellxz/p/11058196.html
今日推荐