Error Codes
Error codes, crisis symptoms & root-cause resolutions
PostgreSQL too many clients already: 6-Step Resolution
Three root causes of FATAL: sorry, too many clients already, single diagnostic query to identify the cause, and permanent mitigation via max_connections and PgBouncer.
PostgreSQL password authentication failed: Root Cause and Fix
Four root causes of psql password authentication failed: incorrect password, md5/SCRAM mismatch, pg_hba.conf rule ordering, and port/cluster confusion. Step-by-step triage.
PostgreSQL connection refused: 8-Step Definitive Triage
Difference between connection refused, timeout, and no pg_hba entry; triage for listen_addresses, port conflicts, firewalls, and Docker container mappings.
PostgreSQL duplicate key Error: Sequence Sync Fix
Root cause of duplicate key violations after restore or bulk migration, one-line setval repair, and an automated schema-wide PL/pgSQL DO block.
PostgreSQL conflict with recovery: hot_standby_feedback
Why replica queries get cancelled due to recovery conflicts, diagnosis via pg_stat_database_conflicts, and three mitigation strategies.
PostgreSQL remaining connection slots reserved Resolution
The relationship of reserved connection slots to max_connections, leveraging the superuser recovery window, and tracking down connection leaks.
PostgreSQL "database is being accessed by other users" Resolution
Safely terminating active sessions before DROP DATABASE, ALLOW_CONNECTIONS isolation, prepared transactions, and replication slot blockers.
PostgreSQL "could not resize shared memory segment" Resolution
The Docker /dev/shm 64MB default limit, parallel query shared memory exhaustion, proper work_mem calculation, and ordered remediation.