Kafka Error BROKER_NOT_AVAILABLE
Error code 8 · Non-retriable Broker
The broker is not available.
Common Causes
- Broker process has crashed or is still starting up and not yet registered in ZooKeeper/KRaft metadata
- Broker is shutting down via controlled shutdown and temporarily marking itself unavailable before deregistering
- ZooKeeper session expired causing the broker to lose its registration, making it appear unavailable to clients
Solutions
- Check broker process status: 'systemctl status kafka' or 'ps aux | grep kafka'; if down, review server.log for the crash reason before restarting
- Verify ZooKeeper connectivity from the broker host: 'echo ruok | nc <zk-host> 2181' and check ZooKeeper logs for session expiry events
- Ensure enough brokers remain available for the configured replication factor; add brokers or reduce min.insync.replicas temporarily if the cluster is under capacity
Diagnostic Commands
# Check broker supported API versions
kafka-broker-api-versions.sh --bootstrap-server <broker>:9092
# Look for related errors in broker logs
grep -E 'ERROR|FATAL|SessionExpired|BrokerNotAvailable' /var/log/kafka/server.log | tail -30
Debugging Kafka errors? Conduktor Console gives you real-time visibility into your cluster. Explore all errors in the Error Decoder.