Practice practical consensus vocabulary: quorum fault tolerance, fencing tokens, lease expiry, and etcd/Zookeeper/Consul usage in production systems.
0 / 5 completed
1 / 5
'The cluster can tolerate 2 node failures with a 5-node quorum.' Why 2?
With N=5 nodes, a majority quorum requires 3 nodes (⌊5/2⌋+1). The cluster can lose 5−3=2 nodes and still have enough nodes to elect a leader and commit writes. Losing 3 nodes means quorum is lost and the cluster becomes unavailable.
2 / 5
What is a 'fencing token' and why is it used?
Fencing tokens prevent the 'zombie leader' problem: a slow node thinks it still holds a lock but is actually expired. Every write includes the fencing token; if the token is older than the current one, the storage layer rejects it — ensuring only the current leader can write.
3 / 5
'The lease expired — waiting for a new leader' means:
A leader lease has a TTL. If the leader fails to send heartbeats (e.g., due to a pause or network issue), the lease expires. Other nodes detect this and start an election. During the gap between lease expiry and new leader election, the cluster may be briefly unavailable for writes.
4 / 5
Which tool is most commonly used as the consensus store in Kubernetes clusters?
etcd is the distributed key-value store at the heart of Kubernetes: it stores all cluster state (pods, services, configs). etcd uses the Raft consensus algorithm to ensure cluster state is consistent across the control plane, even during node failures.
5 / 5
A team says 'we use ___ for service discovery and distributed locking in our microservices.' Which consensus-based tool fits?
Consul (by HashiCorp) provides service discovery, health checking, key-value storage, and distributed locking — all built on the Raft consensus algorithm. It is a common choice for microservices infrastructure alongside etcd and ZooKeeper.