柚子快報邀請碼778899分享:分布式 kafka學(xué)習(xí)問題
柚子快報邀請碼778899分享:分布式 kafka學(xué)習(xí)問題
查看topic列表報超時
報錯如下:
Error while executing topic command : Timed out waiting for a node assignment. Call: listTopics
[2024-02-28 14:36:57,024] ERROR org.apache.kafka.common.errors.TimeoutException: Timed out waiting for a node assignment. Call: listTopics
(kafka.admin.TopicCommand$)
解決方法:修改server.properties文件中的listeners
listeners=PLAINTEXT://ip:9092
停止kafka運行:
bin/kafka-server-stop.sh
重新啟動kafka:
bin/kafka-server-start.sh -daemon config/server.properties
再次查看topic列表,發(fā)現(xiàn)如下報錯:
bin/kafka-topics.sh --bootstrap-server 192.168.15.187:9092 --list
#報錯內(nèi)容
[2024-02-28 14:57:22,420] WARN [AdminClient clientId=adminclient-1] Connection to node -1 (/192.168.15.187:9092) could not be established. Broker may not be available. (org.apache.kafka.clients.NetworkClient)
解決方法:修改server.properties文件中的advertised.listeners即可
advertised.listeners=PLAINTEXT://ip:9092
柚子快報邀請碼778899分享:分布式 kafka學(xué)習(xí)問題
精彩文章
本文內(nèi)容根據(jù)網(wǎng)絡(luò)資料整理,出于傳遞更多信息之目的,不代表金鑰匙跨境贊同其觀點和立場。
轉(zhuǎn)載請注明,如有侵權(quán),聯(lián)系刪除。