1.生产者命令:
./kafka-console-producer.sh --topic mytopic --broker-list node06:9092,node07:9092,node08:9092
2.消费者命令:
./kafka-console-consumer.sh --bootstrap-server node06:9092,node07:9092,node08:9092 --topic mytopic
原文:https://www.cnblogs.com/liuys635/p/11105141.html