一、Kafka 命令行操作
1. Kafka 是要用到zookeeper,那么zookeeper帮Kafka做了什么事呢?
①. 启动zookeeper
②. 从来没启动Kafka的zookeeper节点没有 borkers
yexiang@hadoop2:<zookeeper-3.4.10>$ zkCli.sh -server hadoop3:2181
...
[zk: hadoop3:2181(CONNECTED) 9] ls /
[zookeeper]
③. 启动Kafka再看zookeeper
[zk: hadoop3:2181(CONNECTED) 2] ls /
[cluster, controller_epoch, controller, brokers, zookeeper, test, spark_HA, admin, isr_change_notification, consumers, latest_producer_id_block, config]
- 发现多了 brokers, 其他节点先不管是什么,最起码看到和kafka相关的注册信息了