kafka利用命令查看consumer消费情况

旧版本( <= 0.9)

./kafka-run-class.sh kafka.tools.ConsumerOffsetChecker --group bigdata --topic data-center --zookeeper zk:2181

 或者

/kafka-consumer-offset-checker.sh --group bigdata --topic data-center --zookeeper zk:2181

新版本( > 0.9)

./kafka-consumer-groups.sh --bootstrap-server localhost:9092 --group bigdata --describe

或者想具体看某个topic

 ./kafka-consumer-groups.sh --bootstrap-server localhost:9092  --group bigdata --describe | grep -E "topic|data-center"

 

 

  • https://stackoverflow.com/questions/31061781/what-command-shows-all-of-the-topics-and-offsets-of-partitions-in-kafka  
  • https://www.cloudera.com/documentation/kafka/2-1-x/topics/kafka_command_line.html  

你可能感兴趣的:(kafka,hadoop,大数据,kafka,大数据,zookeeper)