异常信息
ERROR Fatal error during KafkaServer startup. Prepare to shutdown (kafka.server.KafkaServer)
kafka.common.InconsistentClusterIdException: The Cluster ID PI5RJQLhTTKbh2bda3OYMw doesn't match stored
cluster Id Some(fOwbKSAzR5Oy6PIt9dAErg) in meta.properties.
The broker is trying to join the wrong cluster. Configured zookeeper.connect may be wrong.
at kafka.server.KafkaServer.startup(KafkaServer.scala:218)
at kafka.Kafka$.main(Kafka.scala:109)
at kafka.Kafka.main(Kafka.scala)
[2021-08-29 00:22:42,902] INFO shutting down (kafka.server.KafkaServer)
解决方案
- 进入kafka的config路径下,查看
server.properties 查看kafka日志路径,然后进入日志路径下,修改Cluster Id
fOwbKSAzR5Oy6PIt9dAErg -> PI5RJQLhTTKbh2bda3OYMw
- 删除日志目录下的meta.properties文件。
- 或者在存放日志路径下
rm -rf ./* 简单粗暴,但是会删除一些其他日志文件,推荐上面的方法。
|