RICH-ATONE

假如Kafka集群中一个broker宕机无法恢复, 应该如何处理?

如果服务器真的坏了, 只需要新启动一个broker, 把broker.id设置为 损坏的那个broker的id, 就会自动复制过去丢失的数据

How to replace a failed broker?
When a broker fails, Kafka doesn't automatically re-replicate the data on the failed broker to other brokers.
This is because in the common case, one brings down a broker to apply code or config changes, and will bring up the broker quickly afterward.
Re-replicating the data in this case will be wasteful.
In the rarer case that a broker fails completely, one will need to bring up another broker with the same broker id on a new server.
The new broker will automatically replicate the missing data.

 

参考:

https://cwiki.apache.org/confluence/display/KAFKA/FAQ#FAQ-Howtoreplaceafailedbroker? (官网)

https://blog.csdn.net/ashic/article/details/87876824

posted on 2021-08-30 10:30  RICH-ATONE  阅读(399)  评论(0编辑  收藏  举报

导航