Memra

Operating a database

The admin literacy an entry-level role needs.

Running it in production

Beyond queries, a data-systems job expects operational fluency:

  • Loading data fastCOPY streams CSV in/out far faster than row-by-row INSERT (psql's \copy does it client-side). INSERT ... SELECT and generate_series handle bulk transforms.
  • Backupspg_dump / pg_restore for logical backups; understand point-in-time recovery exists.
  • HealthVACUUM/ANALYZE reclaim space and refresh planner statistics (autovacuum does this automatically); pg_stat_activity shows live queries.
  • The psql client\dt lists tables, \d table describes one, \du lists roles.
  • Connections — apps use a connection pool (PgBouncer) because each Postgres connection has real overhead.

You don't need to be a DBA, but knowing these terms — and that they exist — is the difference between a junior who can operate and one who's stuck.

jobtoolnoteload a CSV fastCOPY\copy runs it client-sideback up and restorepg_dump, pg_restorelogical backupreclaim space, refreshstatsVACUUM, ANALYZEautovacuum does itsee what is running nowpg_stat_activityfind the blockerinspect the schema\dt, \d, \duinside psqlmany app connectionsPgBouncerpool them
None of this is querying, and all of it is expected. Knowing the name of the tool is most of the job — the rest is reading its output.
NORMAL ~/memra/learn/postgresql/operating-a-database utf-8 LF