Semester 5: Operating Systems & Networking
Year 2 | Systems | Phase 5 | Weeks 49-58
Semester 5 turns machine-level intuition into operating-system and network reasoning. You should finish this semester able to trace a process through the scheduler, a virtual address through page translation, a shared-memory bug through an interleaving, a write through the file system, and a request through the network stack.
Goal
Build operational understanding of how modern systems schedule work, virtualize memory, coordinate concurrent execution, persist data, and move bytes over the network.
Prerequisites
You should be comfortable with the Semester 4 systems-programming material before starting:
- writing and debugging small C programs
- pointers, stack vs heap, and process address-space basics
- system calls such as
fork,exec,read,write, andwait - basic shell, Linux process inspection, and build workflow habits
If those are weak, review Semester 4 before pushing through this semester. The modules here assume you can already read low-level code and reason about what the kernel is doing.
Phase Completion Contract
You are ready to leave Semester 5 when you can do all of the following without handwaving:
- explain and compare scheduling, paging, synchronization, file-system durability, and transport protocols
- build small working artifacts that exercise processes, memory, concurrency, I/O, and sockets
- diagnose at least one real bug or performance issue in each area using tools rather than guesses
- connect kernel- and network-level behavior to later backend, database, and cloud work
Do not advance if you can repeat definitions but cannot trace behavior on paper or in running code.
Modules
| # | Module | Focus |
|---|---|---|
| 1 | Processes & Scheduling | Process abstraction, scheduling policies, context-switch cost, Linux fairness |
| 2 | Memory Management & Virtual Memory | Paging, TLBs, page faults, allocators, mmap, CoW, NUMA |
| 3 | Concurrency & Synchronization | Races, locks, condition variables, semaphores, deadlock, lock-free basics |
| 4 | File Systems & I/O | Inodes, layouts, journaling, page cache, fsync, epoll, io_uring |
| 5 | Network Protocols & Sockets | IP, TCP/UDP, HTTP, TLS, sockets, concurrent servers, packet debugging |
Core Resources
| Resource | Role This Semester |
|---|---|
| Operating Systems: Three Easy Pieces | Primary OS text for processes, memory, concurrency, and persistence |
| Operating System Concepts | Selective support when you need alternate exposition or more formal treatment |
| Computer Networking: A Top-Down Approach | Primary networking text for layered protocols and transport reasoning |
| Unix Network Programming | Primary systems text for socket APIs and network programming detail |
| Linux tooling and man pages | Operational support for perf, strace, ss, tcpdump, /proc, and related inspection |
Use the module concept pages as the main path. The books support those pages; they are not a second syllabus to read cover to cover.
Cross-Cutting Tracks Active This Semester
| Track | Level | Focus This Semester |
|---|---|---|
| A: Testing and Verification | 3 | Characterization tests, concurrency tests, network integration checks, failure-path validation |
| B: Git, Code Review, CI/CD | 3 | Small reproducible experiments, clean commits, repeatable build/run scripts, artifact notes |
| C: Security Engineering | 2 | Process isolation, memory-safety awareness, basic auth/TLS reasoning, least-privilege defaults |
| D: Observability and Reliability | 1 | Logs, metrics, traces, packet captures, /proc inspection, and simple service health checks |
| E: Engineering Fundamentals | 3 | Linux shell fluency, debugging discipline, measurement before claims, written tradeoff reasoning |
Weekly Arc
| Week | Focus | Modules |
|---|---|---|
| 1 | Process model, scheduler vocabulary, first Gantt-chart drills | Module 1 |
| 2 | Advanced scheduling, context switches, cgroups, first measurement write-up | Module 1 |
| 3 | Paging, TLBs, page-table walks, first perf and /proc memory inspection | Module 2 |
| 4 | Replacement policies, allocators, mmap, CoW, NUMA | Module 2 |
| 5 | Race conditions, mutexes, condition variables, bounded-buffer implementations | Module 3 |
| 6 | Deadlock, fairness, lock-free hazards, concurrency debugging practice | Module 3 |
| 7 | Inodes, on-disk layout, journaling, crash consistency scenarios | Module 4 |
| 8 | Page cache, fsync, I/O models, epoll, small filesystem or event-loop work | Module 4 |
| 9 | IP, TCP/UDP, HTTP, TLS, socket APIs, packet-capture practice | Module 5 |
| 10 | Concurrent server finishing pass, cumulative review, project packaging, exam | Module 5 + semester wrap-up |
Learning Journal Prompts
Write one short entry each week. Keep it concrete.
- Which abstraction felt convincing at first, then broke under a counterexample or measurement?
- What tool gave you the most leverage this week:
strace,perf,/proc,ss,tcpdump, or something else? Why? - What bug or performance claim did you replace with evidence?
- Which tradeoff mattered most this week: fairness vs throughput, latency vs overhead, durability vs speed, or simplicity vs scalability?
Semester Deliverables
By the end of the semester you should have:
- completed all five module quizzes
- produced at least one runnable artifact for each major domain: scheduling or memory simulation, concurrency exercise, filesystem or I/O lab, and networked service
- written short measurement notes using real Linux tools rather than only conceptual explanations
- finished the semester project
- passed the checkpoint gate
- completed the cumulative review
- completed the semester exam
What This Semester Sets Up
Semester 6 depends directly on this one:
- databases assume you understand persistence, caching, and crash recovery
- distributed systems assume you understand concurrency, sockets, and failure over networks
- later cloud and platform work assumes you can inspect system behavior instead of treating the OS and network as black boxes
If Semester 5 is weak, the next two semesters become vocabulary-heavy and intuition-light. Finish this one properly.
Capstone Throughline
Every semester must leave behind evidence that can survive into the final capstone defense.
- Artifact carried forward: networked service and packet analysis.
- What to preserve: Preserve the service implementation, protocol notes, traces, captures, and explanations of latency, reliability, and failure behavior.
- Module threads: Module 1: Processes & Scheduling, Module 2: Memory Management & Virtual Memory, Module 3: Concurrency & Synchronization, Module 4: File Systems & I/O, and Module 5: Network Protocols & Sockets.
- Defense prompt: In Semester 10, explain how this semester's artifact changed a capstone decision, reduced a risk, or made the final system easier to defend.
Model Artifact Calibration
Use the packet capture analysis model artifact when turning network traces into justified diagnostic conclusions.