pg.ddx.io pgsql-performance@postgresql.org mailing list archive
help / color / mirror / Atom feedlarge number of connected connections to postgres database (v8.0)
2+ messages / 2 participants
[nested] [flat]
* large number of connected connections to postgres database (v8.0)
@ 2007-07-17 18:51 Fei Liu <fei.liu@aepnetworks.com>
0 siblings, 1 reply; 2+ messages in thread
From: Fei Liu @ 2007-07-17 18:51 UTC (permalink / raw)
To: pgsql-performance@postgresql.org, Fei Liu <fei.liu@aepnetworks.com>
It appears my multi-thread application (100 connections every 5 seconds)
is stalled when working with postgresql database server. I have limited
number of connections in my connection pool to postgresql to 20. At the
begining, connection is allocated and released from connection pool as
postgres serves data request. The pool can recover from exhaustion. But
very quickly (after about 400 client requests), it seems postgres server
stops serving and connection to postgres server is not released any more
resulting a resource exhausting for clients.
Anyone have experience with the performance aspect of this?
Fei
unix 3 [ ] STREAM CONNECTED 1693655
31976/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693654
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693653
31975/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693652
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693651
31974/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693650
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693649
31973/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693648
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693647
31972/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693646
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693645
31971/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693644
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693641
31969/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693640
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693639
31968/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693638
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693637
31967/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693636
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693585
31941/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693584
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693583
31940/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693582
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693581
31939/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693580
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693579
31938/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693578
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693577
31937/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693576
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693575
31936/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693574
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693573
31935/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693572
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693571
31934/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693570
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693427
31851/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693426
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693425
31777/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693424
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693419
31764/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693418
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693655
31976/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693654
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693653
31975/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693652
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693651
31974/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693650
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693649
31973/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693648
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693647
31972/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693646
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693645
31971/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693644
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693641
31969/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693640
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693639
31968/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693638
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693637
31967/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693636
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693585
31941/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693584
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693583
31940/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693582
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693581
31939/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693580
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693579
31938/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693578
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693577
31937/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693576
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693575
31936/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693574
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693573
31935/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693572
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693571
31934/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693570
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693427
31851/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693426
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693425
31777/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693424
31740/ns_ge_classif
unix 3 [ ] STREAM CONNECTED 1693419
31764/postgres: pos /tmp/.s.PGSQL.5583
unix 3 [ ] STREAM CONNECTED 1693418
31740/ns_ge_classif
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: large number of connected connections to postgres database (v8.0)
@ 2007-07-20 23:28 Josh Berkus <josh@agliodbs.com>
parent: Fei Liu <fei.liu@aepnetworks.com>
0 siblings, 0 replies; 2+ messages in thread
From: Josh Berkus @ 2007-07-20 23:28 UTC (permalink / raw)
To: pgsql-performance; +Cc: Fei Liu <fei.liu@aepnetworks.com>
Fei Liu,
> It appears my multi-thread application (100 connections every 5 seconds)
> is stalled when working with postgresql database server. I have limited
> number of connections in my connection pool to postgresql to 20. At the
> begining, connection is allocated and released from connection pool as
> postgres serves data request. The pool can recover from exhaustion. But
> very quickly (after about 400 client requests), it seems postgres server
> stops serving and connection to postgres server is not released any more
> resulting a resource exhausting for clients.
This sounds more like a problem with your connection pool. Unless
PostgreSQL is slowing down due to CPU/RAM/I/O saturation?
In any case, I doubt the problem is too many connections, or you'd just get
an error message ...
--
--Josh
Josh Berkus
PostgreSQL @ Sun
San Francisco
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2007-07-20 23:28 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2007-07-17 18:51 large number of connected connections to postgres database (v8.0) Fei Liu <fei.liu@aepnetworks.com>
2007-07-20 23:28 ` Josh Berkus <josh@agliodbs.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox