Alright. We were not initially using rack aware strategies. So primary and replica were often spread in the same zone (same rack). We then added rack awareness to the server.properties file and restarted the brokers. But of course the partitions were not spread evenly. Now we will manually spread them over and see if going forward, they remain spread across the zones.
Thanks for the pointers Alex. On Wed, Nov 20, 2024 at 4:11 PM Oleksandr Shulgin < oleksandr.shul...@zalando.de> wrote: > On Wed, Nov 20, 2024 at 11:11 AM Soham Chakraborty <dec.so...@gmail.com> > wrote: > > > Fair enough. For one time task, we can probably use some manual work with > > sprinkling of automation thrown in. I will look into cruise control. > > > > Question: now that Kafka knows about "rack" future assignments should > > strictly be zone aware, is that a correct assessment? IOW, if a partition > > is thrown out and gets reassigned, the leader/replica will be in > different > > zones. > > > > You need to correctly specify the broker.rack[1] in the server properties. > It will be then used by the cluster, as described here: > https://kafka.apache.org/documentation/#basic_ops_racks > > [1]: https://kafka.apache.org/documentation/#brokerconfigs_broker.rack > > -- > Alex >