Distributed Systems
Complete Study Summary — Chapters 1–4
This document summarizes all four chapters: Introduction, Architectures & Naming, Networking
Foundations, and Inter-Process Communication. Written for easy reading and exam
preparation.
Distributed Systems — Study Summary Page 1
Chapter 1 — Introduction to Distributed Systems
1.1 What Is a Distributed System?
A distributed system is a collection of independent computers that communicate over a network
to achieve a common goal, while appearing to users as a single coherent system. Each
computer performs specific tasks and shares resources such as data, processing power, or
storage.
Computer scientist Andrew Tanenbaum defined it as: "A collection of independent computers
that appears to its users as a single coherent system."
Real-World Example
Google Search — when you search, thousands of servers across multiple data centers process your
query, but you experience it as one seamless system. Netflix selects the nearest server to stream
video, reducing delay automatically.
1.2 The 5 Key Characteristics
Characteristic What it means Example
Resource Sharing Hardware, software, and data are shared Employees access the same
across machines — no duplication database regardless of location
needed
Concurrency Many users or processes operate at Thousands of users browse and
exactly the same time order from an online shop
simultaneously
Scalability Add more machines to handle more load Facebook adds servers
— no redesign needed continuously as user traffic
grows
Fault Tolerance If one node fails, another takes over — Cloud storage replicates data
the service keeps running across data centers for
guaranteed availability
Heterogeneity Works across different OS, hardware, and Windows servers, Linux
programming languages via standard databases, and mobile apps
protocols interact through APIs
1.3 The 3 Core Challenges
Network Failures
Distributed Systems — Study Summary Page 2
Distributed systems depend on networks. Packet loss, delays, or hardware faults can break
communication between nodes. Engineers must design fault-tolerant protocols to keep the
system reliable.
Data Consistency
When the same data exists on multiple nodes, every update must be synchronized. If not done
carefully, different nodes end up with different versions of the truth. Distributed databases use
replication protocols and consensus algorithms to solve this.
Security
Many nodes communicating over public networks create a large attack surface. Encryption,
authentication, and access control are essential — especially in financial systems.
1.4 Transparency in Distributed Systems
Transparency means the distributed system hides its internal complexity from users. The user
interacts as if using a single machine, even though many computers are involved behind the
scenes.
Transparency Type What it hides
Access Transparency Resources are accessed the same way regardless of their location
Location Transparency Users do not know which server holds the resource
Replication Transparency Users do not know that multiple copies of data exist
Failure Transparency The system hides component failures from users
Migration Transparency Resources can move to different servers without affecting users
Example
Google Drive — you don't know which server stores your file or that it is replicated across multiple data
centers. It just works.
1.5 Examples of Distributed Systems
• The Internet — the largest distributed system in the world, connecting billions of devices
• Cloud Platforms — AWS, Microsoft Azure, Google Cloud — deploy applications across
thousands of servers
• Online Banking — distributed databases and servers manage transactions across
ATMs, apps, and portals
• Social Media — Facebook, Instagram, X store data across multiple global data centers
for fast access
Distributed Systems — Study Summary Page 3
Chapter 2 — Distributed System Architectures & Naming
2.1 Client–Server Architecture
The most common distributed system model. Clients request services while servers provide
them. Servers handle processing and management; clients handle user interaction.
Communication happens through standard protocols like HTTP or TCP/IP.
Component Role
Client Sends requests (e.g., web browser, mobile banking app)
Server Processes requests and sends back responses
Protocol HTTP, TCP/IP — the communication rules between both
Case Study
Online Banking — the user logs into the banking app (client), which communicates with a secure bank
server to retrieve balances and process transactions.
2.2 Peer-to-Peer (P2P) Architecture
All nodes are equal — each acts as both a client and a server. There is no central authority.
Direct communication between computers without relying on a central server.
Key properties:
• No central server controlling the system
• Nodes share resources directly with each other
• Highly scalable because the workload is distributed
• Network continues functioning even if some nodes fail
Case Study
Bitcoin and Ethereum blockchains — thousands of equal nodes validate transactions and maintain a
distributed ledger without any central authority. BitTorrent is another example where users download
while simultaneously uploading.
2.3 Multi-Tier (3-Tier) Architecture
Divides the system into three separate layers, each with a specific job. This separation improves
scalability, maintainability, and security.
Distributed Systems — Study Summary Page 4
Layer Responsibility Example
Presentation Layer User interface — displays info and Web browser, mobile app,
collects user input. Sends requests to the desktop interface
application layer.
Application Layer Business logic — applies rules, validates Order processing, payment
data, manages workflows. The brain of authorization, recommendation
the system. engine
Data Layer Stores, retrieves, and manages all data. MySQL, PostgreSQL,
Ensures consistency and security. MongoDB, Cassandra
Example
E-commerce website: Presentation = product pages the user sees. Application = order processing
logic. Data = product inventory and customer database.
2.4 Microservices Architecture
An application is broken into small, independent services — each responsible for one specific
function. Services communicate through APIs or messaging systems. Each service can be built,
deployed, and scaled independently.
Key properties:
• Each service performs a single function
• Services communicate through APIs
• Can be written in different programming languages
• Independent deployment and scaling — update one part without touching others
Case Study
Netflix uses hundreds of microservices to manage streaming, recommendations, billing, and
authentication across global data centers — all independently scalable.
2.5 Naming in Distributed Systems
Because resources are spread across many machines, distributed systems need naming
systems so users and applications can find and access them using meaningful names rather
than physical addresses.
Naming Type How it works Example
Flat Naming Unique IDs with no structure or UUIDs: 550e8400-e29b-41d4-
hierarchy. Often generated using a716-446655440000
hash functions.
Structured Naming Hierarchical names that reflect DNS: [Link] → Root
organization or location of resources. → .com → example → www
Distributed Systems — Study Summary Page 5
Attribute-Based Resources identified by their Find all documents created by
properties/metadata. Use queries to 'John' in 2024
search.
Name Resolution Translates a resource name into a DNS converts a domain name into
physical address or location. an IP address
How DNS works (Name Resolution)
1. User types [Link] in browser. 2. Browser sends request to DNS server. 3. DNS
translates the domain to an IP address. 4. Browser connects to the server using the IP address.
Distributed Systems — Study Summary Page 6
Chapter 3 — Networking Foundations for Distributed
Systems
Networking is the core infrastructure that enables distributed nodes to communicate. Without
reliable networking, large-scale systems like cloud computing or streaming platforms cannot
function. Key concepts include network layering, routing, congestion control, and performance
optimization.
3.1 Network Layering — OSI & TCP/IP Models
Network layering organizes communication tasks into separate logical layers. Each layer
handles a specific job and interacts only with the layers immediately above and below it. This
modularity makes complex communication manageable and allows different hardware and
software to work together.
The OSI Model — 7 Layers (Used in education & design)
Layer Name What it does
7 Application Interface for apps — web browsers, email clients
6 Presentation Data translation, encryption, and compression
5 Session Manages and controls communication sessions
4 Transport Reliable end-to-end data transfer — TCP lives here
3 Network Logical addressing and routing of packets — IP lives here
2 Data Link Node-to-node communication using MAC addresses
1 Physical Transmission of raw bits — cables, wireless signals
The TCP/IP Model — 4 Layers (Used on the actual internet)
Layer Function Protocols
Application Communication between apps HTTP, FTP, SMTP
Transport End-to-end communication TCP (reliable), UDP (fast)
Internet Logical addressing and routing IP
Network Access Physical data transmission Ethernet, Wi-Fi
Example
When you visit a website: HTTP sends the request (Application layer). TCP ensures reliable delivery
Distributed Systems — Study Summary Page 7
(Transport layer). IP determines the packet's route (Internet layer). The data physically travels over
cables or Wi-Fi (Network Access).
3.2 Switching and Routing
Switching — within a local network
Switches forward data frames within a local network using MAC addresses. They create
dedicated communication paths between devices and improve efficiency. In data centers, high-
speed switches connect thousands of servers.
Example
In an office network, a switch connects all computers, printers, and servers — allowing them to
communicate directly without broadcasting to every device.
Routing — between different networks
Routers determine the best path for data packets to travel between different networks. They use
routing protocols such as OSPF and BGP to exchange network information and choose optimal
paths. This is what allows distributed systems to communicate across cities and continents.
Example
Sending an email from Cameroon to the USA — the message travels through multiple routers across
different countries before reaching its destination.
3.3 Congestion Control
Congestion happens when network traffic exceeds available bandwidth — causing delays,
packet loss, and retransmissions. Congestion control is how TCP regulates how much data is
sent to prevent the network from being overwhelmed.
TCP uses a value called the congestion window (cwnd) — which determines how much data
can be sent before waiting for acknowledgment. The window grows when the network is stable
and shrinks when congestion is detected.
The 4 TCP Congestion Control Algorithms
Algorithm What it does
Slow Start Starts with a small congestion window and grows it quickly until a
threshold is reached. Despite the name, it ramps up fast.
Congestion Avoidance After the threshold (ssthresh) is reached, growth slows to a linear
increase — being careful to avoid overloading the network.
Fast Retransmit Instead of waiting for a timeout to resend a lost packet, TCP
retransmits immediately after receiving 3 duplicate acknowledgments.
Distributed Systems — Study Summary Page 8
Fast Recovery After packet loss, instead of starting over from scratch, TCP reduces
the window partially and continues — much more efficient.
3.4 Performance Considerations
Metric Definition How to improve it
Latency Time delay between sending a request Edge computing, Content Delivery
and receiving a response Networks (CDNs)
Bandwidth Maximum data that can be transmitted Fiber-optic networks, infrastructure
over a network per unit time upgrades
Throughput Actual rate of successful data Congestion control, optimized
transmission (affected by congestion & protocols
loss)
Load Balancing Distributes requests across multiple Load balancers monitor and redirect
servers to prevent overloading one traffic automatically
node
Case Study — Netflix
Netflix uses CDNs, intelligent routing, and congestion control to deliver video to millions of users
worldwide. Servers are placed in multiple geographic locations to minimize latency and handle peak
traffic.
Distributed Systems — Study Summary Page 9
Chapter 4 — Inter-Process Communication (IPC)
Inter-Process Communication (IPC) refers to the mechanisms that allow processes running on
different machines (or within the same machine) to communicate and coordinate. In distributed
systems, IPC is essential for data exchange, synchronization, and task coordination.
4.1 Message Passing
Message passing is the primary communication mechanism in distributed systems. Processes
exchange information through messages sent across a network. It is especially important when
processes run on different machines that do not share memory.
Mode How it works Best for
Synchronous The sender waits until the receiver Situations requiring
acknowledges the message before coordinated, ordered
continuing interaction
Asynchronous The sender continues execution immediately High-volume cloud systems
without waiting for the receiver's response — improves efficiency
significantly
Case Study — Apache Kafka
Kafka is a messaging platform used by LinkedIn and Netflix to enable reliable asynchronous message
passing between distributed services. Messages are stored until consumed, ensuring no data is lost
even if a service temporarily fails.
4.2 Sockets
A socket is a software interface that acts as an endpoint for sending and receiving data between
processes over a network. Sockets are the foundation of client-server communication — a client
connects to a server using a specific IP address and port number, then data flows in both
directions.
Protocol Characteristics Use cases
TCP Sockets Reliable, ordered, error-checked delivery. Web servers, file transfer,
Slower but guaranteed. banking systems
UDP Sockets Fast but no delivery guarantee. No error Video streaming, online
checking. gaming, live broadcasts
Example
Distributed Systems — Study Summary Page 10
When your web browser retrieves a webpage, it uses a TCP socket to connect to the web server.
HTTP itself is built on top of socket communication.
4.3 Remote Procedure Call (RPC)
RPC allows a program to execute a function on a remote machine as if it were a local function
call. It hides the complexity of network communication from the developer — you write code that
calls a remote service without dealing with low-level networking.
How it works:
• The client calls a function — the client stub intercepts the call and converts it into a
network message
• The message travels over the network to the server
• The server stub receives it, executes the function, and sends the result back
• The client receives the result — as if the function ran locally
Case Study — Google gRPC
Google uses gRPC (a modern RPC framework) to enable communication between thousands of
microservices within their infrastructure. Cloud services widely use gRPC because it is fast, efficient,
and works across many programming languages.
4.4 Multicast Communication
Multicast allows a single sender to transmit data simultaneously to multiple receivers — instead
of sending separate individual messages to each one. This reduces network traffic significantly
and improves efficiency in large distributed environments.
Common use cases:
• Video conferencing systems — one stream, many viewers
• Live streaming platforms — broadcasting to thousands simultaneously
• Distributed databases — synchronizing updates across multiple nodes at once
• Financial trading platforms — delivering real-time stock prices to thousands of clients
Example
An online lecture broadcast — the professor's video stream is sent to hundreds of students
simultaneously using multicast, rather than establishing hundreds of individual connections.
4.5 Additional IPC Concepts
Concept Description Example Technology
Message Queues Store messages until they are processed. RabbitMQ, Apache Kafka
Services communicate reliably even if one
temporarily goes down.
Distributed Systems — Study Summary Page 11
Shared Memory IPC Multiple processes access the same POSIX shared memory
memory region. More common in single-
machine systems.
Event-Driven Actions are triggered when specific events E-commerce order
Communication occur. Systems react asynchronously — notifications, webhooks
highly scalable.
Case Study — Netflix Microservices
Netflix operates thousands of microservices communicating through REST APIs, message queues,
and RPC. This allows them to update individual components without disrupting the entire streaming
platform — scaling globally while maintaining reliability.
4.6 IPC Quick Reference Summary
IPC Mechanism Core idea Key benefit
Message Passing Processes exchange messages Works across machines with no
across a network shared memory
Sockets Network endpoints for bidirectional Low-level, flexible, TCP or UDP
process communication options
Remote Procedure Call Execute remote functions as if they Hides network complexity from
(RPC) were local developers
Multicast One sender transmits to many Reduces network traffic for
receivers simultaneously broadcast scenarios
Message Queues Asynchronous messaging with Decouples services; handles
buffered storage failures gracefully
Event-Driven Systems react when specific events Improves scalability and
are triggered responsiveness
Distributed Systems — Study Summary Page 12