pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Abraham, Danny <danny_abraham@bmc.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-general@postgresql.org <pgsql-general@postgresql.org>
Subject: RE:  Re: too many clients already
Date: Thu, 2 Apr 2020 17:13:58 +0000
Message-ID: <1b2dd9f85ea945dd80d3ceb194115612@phx-exmbprd-01.adprod.bmc.com> (raw)
In-Reply-To: <20255.1585845622@sss.pgh.pa.us>
References: <c7e50c9443eb4ae8a2eec661c1b000f9@phx-exmbprd-01.adprod.bmc.com>
	<17877.1585842715@sss.pgh.pa.us>
	<92f708a939754943bb4e75b47d1a10ba@phx-exmbprd-01.adprod.bmc.com>
	<20255.1585845622@sss.pgh.pa.us>

Agree.

I suspect that this is a mal configured pgpool - the developer thinks that the pool is reusing connections,
While it is, in fact, reopening them.

-----Original Message-----
From: Tom Lane <tgl@sss.pgh.pa.us> 
Sent: Thursday, April 02, 2020 7:40 PM
To: Abraham, Danny <danny_abraham@bmc.com>
Cc: pgsql-general@postgresql.org
Subject: [EXTERNAL] Re: too many clients already

"Abraham, Danny" <danny_abraham@bmc.com> writes:
> Well, I guess the questions is - how do I optimize PG for a stream of very short life checks...

You should be using a connection pooler for a load like that.
PG backends are fairly heavyweight things --- you don't want to fire one up for just a single query, at least not when there are many such queries per second.

I think pgbouncer and pgpool are the most widely used options, but this is a bit outside my expertise.

			regards, tom lane





view thread (12+ messages)

Message-ID: <1b2dd9f85ea945dd80d3ceb194115612@phx-exmbprd-01.adprod.bmc.com>
Permalink:  ../1b2dd9f85ea945dd80d3ceb194115612@phx-exmbprd-01.adprod.bmc.com/
Also on:    postgresql.org/message-id/1b2dd9f85ea945dd80d3ceb194115612@phx-exmbprd-01.adprod.bmc.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: danny_abraham@bmc.com, tgl@sss.pgh.pa.us
  Subject: Re: too many clients already
  In-Reply-To: <1b2dd9f85ea945dd80d3ceb194115612@phx-exmbprd-01.adprod.bmc.com>
  References: <c7e50c9443eb4ae8a2eec661c1b000f9@phx-exmbprd-01.adprod.bmc.com> <17877.1585842715@sss.pgh.pa.us> <92f708a939754943bb4e75b47d1a10ba@phx-exmbprd-01.adprod.bmc.com> <20255.1585845622@sss.pgh.pa.us> <1b2dd9f85ea945dd80d3ceb194115612@phx-exmbprd-01.adprod.bmc.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

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