OS Concepts
The minimum viable mental model of an operating system — processes, threads, scheduling, memory, files, and the kernel that ties it together.
- Reading time
- ~36 min (+43 min optional)
- Level mix
- 5 beginner · 11 intermediate
The operating system is the layer of software you almost never see but constantly depend on. This path covers the seven ideas that, together, explain how a modern OS shares one machine between many programs safely and efficiently.
Read in order — each topic builds on the previous one — and you’ll have a working mental model of what’s happening behind every program you run.
Roadmap
Loading progress...
The big picture
The system software that manages hardware and provides services and abstractions to all other programs.
Running programs
A running instance of a program, with its own memory, file handles, and CPU time — the unit the operating system schedules and isolates.
A single line of execution inside a process — the unit the CPU actually runs. A process can have many threads that share memory.
The part of the OS kernel that decides which thread runs on each CPU at any moment — balancing fairness, responsiveness, and throughput.
- MutexOptional
A synchronization primitive that ensures only one thread at a time can hold it — the basic tool for protecting shared state from data races.
- Context SwitchOptional
The act of saving one thread's CPU state and loading another's so the same CPU core can run a different thread next.
Memory
Fast, temporary storage where a running program keeps the data it is actively using.
A technique that gives each process the illusion of a private, contiguous memory space — built from page tables that map virtual addresses to physical RAM.
- PagingOptional
The mechanism that moves fixed-size pages of memory between RAM and disk on demand — the engine inside virtual memory.
Storage
The layer that organises raw storage into named files and directories, manages free space, and enforces permissions.
- InodeOptional
The on-disk record a Unix-style file system keeps for each file — everything about it except its name and its contents.
The privileged core
The privileged core of an operating system — the only software that talks to hardware directly and the gatekeeper that protects every program from every other.
- System CallOptional
The mechanism a user-space program uses to ask the OS kernel to do something privileged — open a file, send a packet, allocate memory, fork a process.
- InterruptOptional
A hardware signal that pauses the CPU mid-instruction so the OS can react to an event — a keystroke, a packet, a timer tick.
- ShellOptional
The program that reads the commands you type, expands and parses them, and asks the OS to run them — the text interface between a user and the operating system.
- DaemonOptional
A long-running background process with no controlling terminal, usually started at boot and supervised by the system, that quietly does work or waits for requests.