A client request becomes a backend process, a query tree, an iterator plan, shared pages, visible row versions, and durable WAL. Follow that journey once; every subsystem gets a permanent place in your mental model.
Choose a workload. Each beat lights the process, memory structure, or durable artifact that owns the next decision.
Read journey
Follow one SELECT
A read becomes a typed query tree, a costed plan, an iterator run, and finally a snapshot-approved row.
01
Process
A backend owns the request
The postmaster accepts the connection and a dedicated backend handles that session. Shared structures coordinate it with every other backend.
Keep this: The planner chooses. The executor pulls. The snapshot judges.
02 / Open the machine
One engine. Several systems.
Peel the X-ray by system, hover a boundary for why it exists, then pin it for evidence. PostgreSQL is not a pile of boxes, it is concurrent systems sharing one engine body.
PostgreSQL engine · X-ray
Architectural cutaway
One engine body. Peel a system, hover a boundary, or replay an incident path.
Hover a boundary for the short card · click to pin selection and open evidence below · peel a layer to see one system through the same engine.
Frame + crew
Postmaster & backends
One postmaster process supervises; each client session is typically its own backend process doing work for that connection.
ExampleIn psql: SELECT pid, usename, state, wait_event_type, wait_event, query_start FROM pg_stat_activity ORDER BY query_start NULLS LAST; Find idle-in-transaction.
Sessionspg_stat_activity
Waitswait_event
I/O pathpg_stat_io
Durabilitypg_stat_wal
Process & memory / Frame + crew
Postmaster & backends
One postmaster process supervises; each client session is typically its own backend process doing work for that connection.
Failure signature
Connection storms, stuck sessions, or “too many connections”, the crew is oversized or idle workers hold resources.
First measurement
In psql: SELECT pid, usename, state, wait_event_type, wait_event, query_start FROM pg_stat_activity ORDER BY query_start NULLS LAST; Find idle-in-transaction.
Source boundary
Process model, postmaster forks backends (see official docs: Architecture / Connections).