KatInterview

Minimize broadcast time for 100 GB file to 1,000 cluster nodes

System DesignModel answer
MediumModel answerSystem Designdistributed-systemsnetworkingfile-distribution

Last updated

Design a fast file distribution system to deliver a 100 GB checkpoint from one origin to 1,000 workers, minimizing total transfer time.

Problem Context

You're building a file broadcast system for a machine learning cluster. Before launching a training job, you need to distribute a 100 GB model checkpoint from one storage server to 1,000 worker machines. The faster this distribution completes, the less time expensive GPUs sit idle.

Constraints and Environment

  • File size: 100 GB (single immutable file)
  • Target fleet: 1,000 worker nodes across roughly 25 racks in one datacenter
  • Network hardware: Each machine has a 25 Gbps network card; racks are connected through spine switches with typical oversubscription ratios
  • Success criteria: All workers have a verified, complete copy in minimal elapsed time

Your Task

Design a distribution system that achieves close to the theoretical minimum transfer time. Address:

  1. Bottleneck identification: Calculate how long different approaches would take and identify the fundamental limit
  2. Data partitioning: How should the file be split and transmitted to enable parallelism?
  3. Network topology: How do you arrange transfers to avoid congestion on inter-rack links?
  4. Reliability: How do you handle node failures or slowdowns without blocking the entire fleet?
  5. Coordination: What control plane is needed to orchestrate transfers and verify completion?

Provide concrete numbers, explain trade-offs, and describe the mechanisms that make your design work.

Hints

Hint 1

Calculate the time if one server uploads sequentially versus if every node can download at full speed simultaneously

Hint 2

Consider how pipelining techniques (like in networks or video streaming) can overlap transfers

Hint 3

Think about building a distribution graph where nodes relay data to each other, keeping rack boundaries in mind