Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 06F70632C84 for ; Fri, 9 Jul 2010 02:56:03 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 02964-01 for ; Fri, 9 Jul 2010 05:55:54 +0000 (UTC) X-Greylist: delayed 00:07:03.284042 by SQLgrey-1.7.6 Received: from serenity.inversion.ee (serenity.inversion.ee [194.204.33.112]) by mail.postgresql.org (Postfix) with ESMTP id 4C65863288E for ; Fri, 9 Jul 2010 02:55:54 -0300 (ADT) Received: by serenity.inversion.ee (Postfix, from userid 108) id 5BDCAE34420; Fri, 9 Jul 2010 07:31:04 +0300 (EEST) Received: from [IPv6:::1] (localhost [127.0.0.1]) by serenity.inversion.ee (Postfix) with ESMTP id DC207E343F2; Fri, 9 Jul 2010 07:31:03 +0300 (EEST) Subject: Re: Need help in performance tuning. From: Hannu Krosing To: Tom Lane Cc: Samuel Gendler , pgsql-performance@postgresql.org In-Reply-To: <8760.1278650566@sss.pgh.pa.us> References: <4C369346.6010501@postnewspapers.com.au> <8760.1278650566@sss.pgh.pa.us> Content-Type: text/plain; charset="UTF-8" Date: Fri, 09 Jul 2010 08:48:49 +0300 Message-ID: <1278654529.7216.20.camel@hvost> Mime-Version: 1.0 X-Mailer: Evolution 2.28.1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-10 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201007/212 X-Sequence-Number: 39601 On Fri, 2010-07-09 at 00:42 -0400, Tom Lane wrote: > Samuel Gendler writes: > > On Thu, Jul 8, 2010 at 8:11 PM, Craig Ringer > > wrote: > >> If you're not using a connection pool, start using one. > > > I see this issue and subsequent advice cross this list awfully > > frequently. Is there in architectural reason why postgres itself > > cannot pool incoming connections in order to eliminate the requirement > > for an external pool? > > Perhaps not, but there's no obvious benefit either. Since there's > More Than One Way To Do It, it seems more practical to keep that as a > separate problem that can be solved by a choice of add-on packages. One example where you need a separate connection pool is pooling really large number of connections, which you may want to do on another host than the database itself is running. For example pgbouncer had to add option to use incoming unix sockets, because they run into the IP socket port number limit (a little above 31k, or more exactly 63k/2. And unix sockets can be used only on local host . -- Hannu Krosing http://www.2ndQuadrant.com PostgreSQL Scalability and Availability Services, Consulting and Training