Vahid Hashemian created KAFKA-3091: -------------------------------------- Summary: Broker with an invalid id would not start when its id is updated to a new valid one Key: KAFKA-3091 URL: https://issues.apache.org/jira/browse/KAFKA-3091 Project: Kafka Issue Type: Bug Components: core Affects Versions: 0.9.0.0 Reporter: Vahid Hashemian Priority: Minor
Setup being used: - Kafka 0.9.0 - Two servers: -- server 1: zookeeper and 3 brokers (ids: 0, 1, 2) -- server 2: 2 brokers (ids: 10 and 1 -> 11) When on server 2 the second broker with initial id of 1 is started an error returned indicating the id 1 is in use. When the corresponding servers.properties file is updated and id is changed to 11 the broker would no longer start. The following error is returned: [2016-01-12 13:40:22,145] FATAL Fatal error during KafkaServer startup. Prepare to shutdown (kafka.server.KafkaServer) kafka.common.InconsistentBrokerIdException: Configured brokerId 11 doesn't match stored brokerId 1 in meta.properties at kafka.server.KafkaServer.getBrokerId(KafkaServer.scala:630) at kafka.server.KafkaServer.startup(KafkaServer.scala:175) at kafka.server.KafkaServerStartable.startup(KafkaServerStartable.scala:37) at kafka.Kafka$.main(Kafka.scala:67) at kafka.Kafka.main(Kafka.scala) [2016-01-12 13:40:22,147] INFO shutting down (kafka.server.KafkaServer) [2016-01-12 13:40:22,148] INFO Shutting down. (kafka.log.LogManager) [2016-01-12 13:40:22,153] INFO Shutdown complete. (kafka.log.LogManager) [2016-01-12 13:40:22,153] INFO Terminate ZkClient event thread. (org.I0Itec.zkclient.ZkEventThread) [2016-01-12 13:40:22,155] INFO Session: 0x15237b0b6270014 closed (org.apache.zookeeper.ZooKeeper) [2016-01-12 13:40:22,155] INFO EventThread shut down (org.apache.zookeeper.ClientCnxn) [2016-01-12 13:40:22,156] INFO shut down completed (kafka.server.KafkaServer) [2016-01-12 13:40:22,156] FATAL Fatal error during KafkaServerStartable startup. Prepare to shutdown (kafka.server.KafkaServerStartable) kafka.common.InconsistentBrokerIdException: Configured brokerId 11 doesn't match stored brokerId 1 in meta.properties at kafka.server.KafkaServer.getBrokerId(KafkaServer.scala:630) at kafka.server.KafkaServer.startup(KafkaServer.scala:175) at kafka.server.KafkaServerStartable.startup(KafkaServerStartable.scala:37) at kafka.Kafka$.main(Kafka.scala:67) at kafka.Kafka.main(Kafka.scala) [2016-01-12 13:40:22,157] INFO shutting down (kafka.server.KafkaServer) I looked at existing JIRA tickets referencing this error but none seemed to describe the exact scenario as the one here. For example, http://mail-archives.apache.org/mod_mbox/ambari-dev/201509.mbox/%3cjira.12853011.1438969299000.304540.1441907025...@atlassian.jira%3E indicates restarting all brokers as a workaround, but that workaround would not fix the issue reported here. Even a zookeeper restart would not fix this one. And upon further testing it appears the number of servers is irrelevant here, and the same issue would surface in a one server setup too. -- This message was sent by Atlassian JIRA (v6.3.4#6332)