by slantedview · 10y ago · 0 comments
max_connections sets exactly that: the maximum number of client
connections allowed. This is very important to some of the
below parameters (particularly work_mem) because there are some
memory resources that are or can be allocated on a per-client
basis, so the maximum number of clients suggests the maximum
possible memory use. Generally, PostgreSQL on good hardware can
support a few hundred connections. If you want to have
thousands instead, you should consider using connection pooling
software to reduce the connection overhead.
Replication, Clustering, and Connection Pooling [1][0] https://wiki.postgresql.org/wiki/Tuning_Your_PostgreSQL_Serv...
[1] https://wiki.postgresql.org/wiki/Replication,_Clustering,_an...
This means the PG has explicit IPC overhead, vs the quick and seductive path (to the dark side?) of simply sharing memory between threads. Safety vs speed.