kafka.common.InconsistentClusterIdException: The Cluster ID xxx doesn’t match stored clusterId

created at 05-29-2022 views: 2

problem

Zookeeper is running normally, but the kafka process is immediately given up. . .

Check server.log and find that id does not match

Fatal error during KafkaServer startup. Prepare to shutdown (kafka.server.KafkaServer)
kafka.common.InconsistentClusterIdException: The Cluster ID YOIAaEFQTxOxKawUXmUcGw doesn’t match stored clusterId Some(VZ-h-2APRFydv_OisSEfxQ) in meta.properties. The broker is trying to join the wrong cluster. Configured zookeeper.connect may be wrong.

solution

Modify the id of meta.properties (in ${kafka_home}/logs) and unify it with the error message.

created at:05-29-2022
edited at: 05-29-2022: