What is a distributed system?

Why Interviewers Ask This

This is a classic screening question for System Design roles. Hiring managers ask it early in interviews to gauge your baseline understanding and determine if you can communicate technical concepts clearly.

Answer

A distributed system is a collection of independent computers that appear to users as a single coherent system, coordinating through message passing over a network. The components share state, divide work, and coordinate to achieve a common goal. Characteristics: (1) Components run on separate machines; (2) Communicate via network (unreliable, with latency); (3) No shared clock (cannot synchronize perfectly); (4) Partial failures (some nodes fail while others continue); (5) Concurrent execution. Key challenges: (1) Network unreliability: messages may be lost, delayed, duplicated, or reordered; (2) Partial failure: impossible to distinguish a slow node from a failed one; (3) No global clock: can't tell the exact order of events across machines (use logical clocks — Lamport timestamps, vector clocks); (4) Concurrency: race conditions, deadlocks across nodes; (5) Consistency vs availability trade-off (CAP theorem); (6) Byzantine failures: nodes may behave arbitrarily or maliciously. Fallacies of distributed computing (L. Peter Deutsch): 1. The network is reliable. 2. Latency is zero. 3. Bandwidth is infinite. 4. The network is secure. 5. Topology doesn't change. 6. There is one administrator. 7. Transport cost is zero. 8. The network is homogeneous. Understanding these fallacies guides robust distributed system design.

Pro Tip

This topic has System Design-specific nuances that differ from general programming. Highlighting those nuances in your answer shows expertise rather than generic knowledge.