📖 ~1 min read
Table of contents
Symptom & Impact
Applications fail with `FATAL: sorry, too many clients already` during peak load.
Environment & Reproduction
Seen on database hosts that consolidated workloads or where pooling is disabled.
Root Cause Analysis
Connections from app servers exceed `max_connections` because no connection pooler is in place.
Quick Triage
Check current connections with `SELECT count(*) FROM pg_stat_activity;`.
Step-by-Step Diagnosis
Inspect `postgresql.conf` for `max_connections` and review `pg_stat_activity` states.

Solution – Primary Fix
Deploy pgbouncer in transaction pooling mode and point apps to it.
Still having issues? Our IT Solutions & Services team can diagnose and resolve this for you. Get in touch for a free consultation.

Solution – Alternative Approaches
Temporarily raise `max_connections` and tune `shared_buffers` to handle the surge.
Verification & Acceptance Criteria
Connection counts stay below 70% of `max_connections` and errors stop.
Rollback Plan
Roll back tuning changes via configuration backups if memory pressure spikes.
Prevention & Hardening
Standardise pooling for all production databases and monitor active sessions.
Related Errors & Cross-Refs
Pairs with high context-switch counts and idle-in-transaction sessions.
Related tutorial: View the step-by-step tutorial for sles-15.
View all sles-15 tutorials on the Tutorials Hub →
Browse all common problems & solutions on the Tutorials Hub.
References & Further Reading
SUSE PostgreSQL packaging and pgbouncer integration notes.
Need Expert Help?
If you cannot resolve this yourself, our team offers hands-on Server Management, Managed IT Services, and flexible Support Plans. Contact us today — we respond within one business day.