简体   繁体   中英

Kafka Replication factor increase post issue

I am using a 3 broker Kafka cluster in prod. Earlier the replication factor was 2 . Now I want to increase the replication factor to 3. I have executed the kafka-reassignment-partions.sh file and it go executed successfully. Post execution when I am executing the describe command it is showing 3 brokers in the ISR list , but for all partions , I am having the same leader (Broker 1 as the Leader).

Please suggest

As far as I know the order you put in the "replicas" field reflect which broker will be the leader for that partition so have the same [1,2,3] sequence for all the partitions and broker 1 is always in the same first position so it will be the leader for that partition. You should change that order putting in the first position the broker-id you want being the leader for the corresponding partition. After that you have to run the preferred replica election tool.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM