Kafka Error FENCED_MEMBER_EPOCH
Error code 110 · Non-retriable Consumer
The member epoch is fenced by the group coordinator. The member must abandon all its partitions and rejoin.
Common Causes
- The consumer sent a heartbeat or fetch request with a stale member epoch after the group coordinator already advanced the epoch (e.g., due to a rebalance or another member joining/leaving), causing the coordinator to fence the outdated member.
- Network partition or GC pause caused the consumer to miss heartbeat deadlines; by the time it reconnected, the group had rebalanced and the old epoch was invalidated.
- Consumer client is running an older version of the new consumer group protocol (KIP-848) that doesn't properly track epoch increments from the coordinator.
Solutions
- The fenced consumer must stop using its current assignment and rejoin the group to obtain a fresh member epoch; standard Kafka clients handle this by issuing a new ConsumerGroupHeartbeat sequence automatically.
- For groups using the consumer protocol, tune the broker-side group.consumer.session.timeout.ms and group.consumer.heartbeat.interval.ms if members are being fenced because long GC pauses or network hiccups make them look dead.
- Ensure all consumers in the group are on the same Kafka client version supporting the new consumer protocol (Kafka 3.7+ for KIP-848). Mixed client versions cause epoch negotiation issues.
Diagnostic Commands
# Describe consumer group offsets and lag
kafka-consumer-groups.sh --bootstrap-server localhost:9092 --describe --group <group-id>
# Look for heartbeat/session events in logs
grep 'FENCED_MEMBER_EPOCH\|fenced\|ConsumerGroupHeartbeat' /var/log/kafka/server.log | tail -50Related APIs
This error can be returned by: ConsumerGroupHeartbeat
Debugging Kafka errors? Conduktor Console gives you real-time visibility into your cluster. Explore all errors in the Error Decoder.