PostgreSQL Don'ts and Dos
summary
If backups take 48 hours with pg_dump expect a 5–6 day restore; switch to binary backups like pg_basebackup and a PITR-capable tool such as pg_backrest (parallel, retention, faster restores). Tune work_mem before shared_buffers, avoid thousands of DB connections—use a pool and size for worst-case (rolling upgrades add connections). Export metrics to Prometheus/Grafana and enable pg_stat_statements. Use SCRAM (SCRAM-SHA-256), prefer UUIDv7 or int keys, avoid OFFSET pagination, use RETURNING, range types, filter/window aggregates.
AI-written summary · about
chapters (13)
- 0:00Introduction
- 3:30Backups and common mistakes
- 12:22Tuning PostgreSQL parameters
- 17:37Connection pooler best practices
- 20:43Monitoring and baselines
- 32:16Security password and encryption
- 36:44Developer data types and UUIDs
- 41:19Integer vs bigint
- 43:52Enums and range types
- 48:04Pagination and ORM usage
- 51:10Advanced SQL features
- 56:31Summary
- 57:37Q&A on backups and pgBackRest
related talks
50mPostgreSQL Backup and Recovery Methods
57mPostgreSQL When It's Not Your Job
56mPostgreSQL Backup Strategies
46mAn ultimate guide to upgrading your PostgreSQL installation
50mAn ultimate guide to upgrading your PostgreSQL installation
02h 30mTutorial
51mHow Postgres is misused and abused in the wild
37mPostgres at Any Scale
