Kafka Error DUPLICATE_BROKER_REGISTRATION
Error code 101 · Non-retriable KRaft
This broker ID is already in use.
Common Causes
- Two broker processes were started with the same node.id (KRaft) or broker.id (ZooKeeper mode) due to a misconfigured config file or copy-paste error
- A broker was restarted and the old process did not fully terminate before the new one attempted to register with the KRaft controller
- A new VM or container was provisioned from an image that reused another broker's config or data directory, so the replacement tried to register with the same identity
Solutions
- Ensure each broker has a unique node.id in KRaft mode (or broker.id in ZooKeeper mode) before starting it; audit every server.properties used by automation
- Confirm the old broker process has terminated (check PID file and process list) before starting the replacement with the same ID
- Do not clone another broker's meta.properties or data directory onto a new node. If you are replacing a broker, provision a fresh data directory and format storage for that node's own identity
Diagnostic Commands
# Show KRaft quorum replication details
kafka-metadata-quorum.sh --bootstrap-server localhost:9092 describe --replication | grep -E 'NodeId|Broker'
# Look for duplicate registration events
grep 'DuplicateBrokerRegistration\|already registered\|node.id\|broker.id' /var/log/kafka/server.log | tail -20Related APIs
This error can be returned by: BrokerRegistration
Debugging Kafka errors? Conduktor Console gives you real-time visibility into your cluster. Explore all errors in the Error Decoder.