What do the words on this site actually mean?
One picture and one line each. No prior knowledge. Five minutes.
A database is a library. Tables are shelves. Rows are books. The card catalog is the index, the loan desk is where transactions happen, and the branch libraries are the shards.
Learn the library version of each concept, and the database version is the same job with files instead of paper. When a term below feels abstract, picture the shelf.
An index is the card catalog. It trades a little disk and a little write cost for lookups that stay fast as the shelves fill.
One fact, one place. The author's name lives on a single author card, so a correction has exactly one place to land.
A join matches two tables on a shared key. The key is what makes it cheap. Without a key, it reads both tables end to end.
A transaction groups steps so they commit together or roll back together. There is no half-borrowed state.
Four promises, one line each. Durable is the promise the log pays for: the record hits disk before the commit returns.
A deadlock is a circle of waiting. Nobody can move, so the database picks one transaction, rolls it back, and lets the other finish.
Partitioning splits one table into parts on the same server. A query that names the part reads only that part.
Sharding is partitioning across machines. It buys room to grow, and the price is that a query spanning branches is a query across the network.
A replica replays the primary's log, so it holds the same books. When the primary fails, the copy is what keeps the doors open, once something promotes it to primary. The copy can trail the original, and something still has to promote it before it can take writes; the next concept covers the lag.
Writes go to the primary, reads go to the copies. The split only works if your readers can live with a copy a few seconds behind.
That is the vocabulary. Next: Start here, one insert end to end, then the three rules that run every database on this site.
The primary is slow because of writes. Someone suggests adding two read replicas. In your own words, why will that not help, and what would?
Write your answer down first. Then open mine.
Why not: every replica has to apply every write the primary makes. Replicas take reads off the primary; they do nothing for writes. They also add lag, so anything that reads its own writes from a replica may not see them.
What helps: making each write cheaper (fewer indexes, smaller rows, batching), moving writes that do not need to be there (sessions, counters) to a store built for them, and only then splitting the writes across several primaries.
How do databases actually work? From one row on disk to transactions: the words you need, PostgreSQL, MySQL and MongoDB from the files up, then Redis, Cassandra and vector search, side by side, and the query and concurrency traps.