14. Replication
Interview questions
Interview questions (with the counter-questions you'll get)
Q1. Why replicate a database?
They're testing: knowing the goals and the limits.
Think about your answer first, then open it.
Q2. Synchronous vs asynchronous replication?
They're testing: the core trade-off.
Think about your answer first, then open it.
Q3. What is replication lag, and what problems does it cause?
They're testing: real-world experience.
Think about your answer first, then open it.
Q4. How does failover work, and what can go wrong?
They're testing: depth on a hard operational problem.
Think about your answer first, then open it.
Q5. What is split brain, and how do you prevent it?
They're testing: distributed-systems fundamentals.
Think about your answer first, then open it.
Q6. When would you use multi-leader replication?
They're testing: knowing it's powerful but dangerous.
Think about your answer first, then open it.
Q7. Explain quorums: N, W and R.
They're testing: leaderless replication.
Think about your answer first, then open it.
Q8. How do you route reads between the primary and replicas?
They're testing: practical design.
Think about your answer first, then open it.
Q9. Replication isn't a backup. Why not?
They're testing: operational wisdom.
Think about your answer first, then open it.
Q10. A replica keeps falling further behind. What do you check?
They're testing: debugging.
Think about your answer first, then open it.