zookeeper is not a recognized option

zookeeper is not a recognized option

 

创建消费者时候报错:

.\bin\windows\kafka-console-consumer.bat --zookeeper localhost:2181 --topic ads_log 
zookeeper is not a recognized option

问题原因:

新版本kafka中,--zookeeper这种启动方式已删除。

解决办法:

0.90版本之后启动消费者的方法如下:

.\bin\windows\kafka-topics.bat  --bootstrap-server localhost:9092 --topic ads_log --from-beginning

 

 --bootstrap-server 参数

 创建主题:都可以

.\bin\windows\kafka-topics.bat --create  --bootstrap-server localhost:9092 --replication-factor 1 --partitions 3 --topic ads

.\bin\windows\kafka-topics.bat --create  --zookeeper localhost:2181 --replication-factor 1 --partitions 3 --topic ads

 

完结!

 

 

 

 

posted @   wqbin  阅读(2915)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· DeepSeek “源神”启动!「GitHub 热点速览」
· 我与微信审核的“相爱相杀”看个人小程序副业
· 微软正式发布.NET 10 Preview 1:开启下一代开发框架新篇章
· C# 集成 DeepSeek 模型实现 AI 私有化(本地部署与 API 调用教程)
· spring官宣接入deepseek,真的太香了~
历史上的今天:
2019-01-03 关于中间表,结果表,和依赖表
2019-01-03 np中的温故知新
2019-01-03 按列排序,行变换
2019-01-03 np中的随机函数
点击右上角即可分享
微信分享提示