pgBouncer for connection pooling

pgBouncer for connection pooling

am 23.08.2010 16:38:14 von Kieren Scott

--_d16c902b-344d-418a-a65c-5be5b6b1d768_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable


Hi=2C

I have a web-based application (drupal) which uses PHP to make connections =
to a back-end postgresql 8.3 server. The application and database are on se=
parate servers=2C but as we can get 20+ concurrent connections on the datab=
ase I've looked at pgBouncer to try and reduce the overhead of new connecti=
ons on the database. I currently have pgBouncer running on the same server =
as my postgres database but I was wondering whether this is a recommended s=
etup - are the performance benefits of using a connection pooler overshadow=
ed by the overhead of running pgBouncer on the same server as the database?

How are other people using pgBouncer? E.g. on a separate server from the da=
tabase etc...?

Thanks in advance.
=

--_d16c902b-344d-418a-a65c-5be5b6b1d768_
Content-Type: text/html; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable






Hi=2C

I have a web-based application (drupal) which uses PHP to make=
connections to a back-end postgresql 8.3 server. The application and datab=
ase are on separate servers=2C but as we can get 20+ concurrent connections=
on the database I've looked at pgBouncer to try and reduce the overhead of=
new connections on the database. I currently have pgBouncer running on the=
same server as my postgres database but I was wondering whether this is a =
recommended setup - are the performance benefits of using a connection pool=
er overshadowed by the overhead of running pgBouncer on the same server as =
the database?

How are other people using pgBouncer? E.g. on a separa=
te server from the database etc...?

Thanks in advance.
=

=

--_d16c902b-344d-418a-a65c-5be5b6b1d768_--

Re: pgBouncer for connection pooling

am 23.08.2010 18:02:31 von Joshua Drake

On Mon, 2010-08-23 at 14:38 +0000, Kieren Scott wrote:
> Hi,
>
> I have a web-based application (drupal) which uses PHP to make
> connections to a back-end postgresql 8.3 server. The application and
> database are on separate servers, but as we can get 20+ concurrent
> connections on the database I've looked at pgBouncer to try and reduce
> the overhead of new connections on the database. I currently have
> pgBouncer running on the same server as my postgres database but I was
> wondering whether this is a recommended setup - are the performance
> benefits of using a connection pooler overshadowed by the overhead of
> running pgBouncer on the same server as the database?
>
> How are other people using pgBouncer? E.g. on a separate server from
> the database etc...?

We use it in both on separate boxes as well as local. As long as your
machine is handling the connection processing of the pooler fine, I
wouldn't worry about it. There are some specific high end off machine
things you can do (point at different databases on different machines
from a single pooler) that is cool but for just a Drupal website it is
probably not required.

JD

--
PostgreSQL.org Major Contributor
Command Prompt, Inc: http://www.commandprompt.com/ - 509.416.6579
Consulting, Training, Support, Custom Development, Engineering
http://twitter.com/cmdpromptinc | http://identi.ca/commandprompt


--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Re: pgBouncer for connection pooling

am 23.08.2010 21:55:55 von Kieren Scott

--_55f29cef-9165-43cc-a58c-5d255cf9546a_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable


Many thanks.

> Subject: Re: [ADMIN] pgBouncer for connection pooling
> From: jd@commandprompt.com
> To: kierenscott@hotmail.com
> CC: pgsql-admin@postgresql.org
> Date: Mon=2C 23 Aug 2010 09:02:31 -0700
>=20
> On Mon=2C 2010-08-23 at 14:38 +0000=2C Kieren Scott wrote:
> > Hi=2C
> >=20
> > I have a web-based application (drupal) which uses PHP to make
> > connections to a back-end postgresql 8.3 server. The application and
> > database are on separate servers=2C but as we can get 20+ concurrent
> > connections on the database I've looked at pgBouncer to try and reduce
> > the overhead of new connections on the database. I currently have
> > pgBouncer running on the same server as my postgres database but I was
> > wondering whether this is a recommended setup - are the performance
> > benefits of using a connection pooler overshadowed by the overhead of
> > running pgBouncer on the same server as the database?
> >=20
> > How are other people using pgBouncer? E.g. on a separate server from
> > the database etc...?
>=20
> We use it in both on separate boxes as well as local. As long as your
> machine is handling the connection processing of the pooler fine=2C I
> wouldn't worry about it. There are some specific high end off machine
> things you can do (point at different databases on different machines
> from a single pooler) that is cool but for just a Drupal website it is
> probably not required.
>=20
> JD
>=20
> --=20
> PostgreSQL.org Major Contributor
> Command Prompt=2C Inc: http://www.commandprompt.com/ - 509.416.6579
> Consulting=2C Training=2C Support=2C Custom Development=2C Engineering
> http://twitter.com/cmdpromptinc | http://identi.ca/commandprompt
>=20
>=20
> --=20
> Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-admin
=

--_55f29cef-9165-43cc-a58c-5d255cf9546a_
Content-Type: text/html; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable






Many thanks.

>=3B Subject: Re: [ADMIN] pgBouncer for connection po=
oling
>=3B From: jd@commandprompt.com
>=3B To: kierenscott@hotmai=
l.com
>=3B CC: pgsql-admin@postgresql.org
>=3B Date: Mon=2C 23 Au=
g 2010 09:02:31 -0700
>=3B
>=3B On Mon=2C 2010-08-23 at 14:38 +0=
000=2C Kieren Scott wrote:
>=3B >=3B Hi=2C
>=3B >=3B
>=
=3B >=3B I have a web-based application (drupal) which uses PHP to make r>>=3B >=3B connections to a back-end postgresql 8.3 server. The applic=
ation and
>=3B >=3B database are on separate servers=2C but as we ca=
n get 20+ concurrent
>=3B >=3B connections on the database I've look=
ed at pgBouncer to try and reduce
>=3B >=3B the overhead of new conn=
ections on the database. I currently have
>=3B >=3B pgBouncer runnin=
g on the same server as my postgres database but I was
>=3B >=3B won=
dering whether this is a recommended setup - are the performance
>=3B =
>=3B benefits of using a connection pooler overshadowed by the overhead o=
f
>=3B >=3B running pgBouncer on the same server as the database? >>=3B >=3B
>=3B >=3B How are other people using pgBouncer? E.g.=
on a separate server from
>=3B >=3B the database etc...?
>=3B =

>=3B We use it in both on separate boxes as well as local. As long as=
your
>=3B machine is handling the connection processing of the pooler=
fine=2C I
>=3B wouldn't worry about it. There are some specific high =
end off machine
>=3B things you can do (point at different databases o=
n different machines
>=3B from a single pooler) that is cool but for j=
ust a Drupal website it is
>=3B probably not required.
>=3B
&=
gt=3B JD
>=3B
>=3B --
>=3B PostgreSQL.org Major Contributo=
r
>=3B Command Prompt=2C Inc: http://www.commandprompt.com/ - 509.416.=
6579
>=3B Consulting=2C Training=2C Support=2C Custom Development=2C E=
ngineering
>=3B http://twitter.com/cmdpromptinc | http://identi.ca/com=
mandprompt
>=3B
>=3B
>=3B --
>=3B Sent via pgsql-adm=
in mailing list (pgsql-admin@postgresql.org)
>=3B To make changes to y=
our subscription:
>=3B http://www.postgresql.org/mailpref/pgsql-admin<=
br>
=

--_55f29cef-9165-43cc-a58c-5d255cf9546a_--

Re: pgBouncer for connection pooling

am 24.08.2010 06:15:34 von Benjamin Krajmalnik

This is a multi-part message in MIME format.

------_=_NextPart_001_01CB4343.6B86B8F4
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

I have pgbouncer running on the same server, and I get over 2000 calls
to a php page per minute.

Each call does inserts data digests into partitioned tables.

I also have a multi-threaded daemon connected to the same database
running background operations on the data coming in.

Works flawlessly.

BTW, 20 connections is not a heavy load at all.

In my application, pgbouncer has opened about 60 backends to handle the
cases where I have a high oncurrency of data coming in at once, but
usually the # non-idle connections is < 10.

=20

=20

From: pgsql-admin-owner@postgresql.org
[mailto:pgsql-admin-owner@postgresql.org] On Behalf Of Kieren Scott
Sent: Monday, August 23, 2010 8:38 AM
To: pgsql-admin@postgresql.org
Subject: [ADMIN] pgBouncer for connection pooling

=20

Hi,

I have a web-based application (drupal) which uses PHP to make
connections to a back-end postgresql 8.3 server. The application and
database are on separate servers, but as we can get 20+ concurrent
connections on the database I've looked at pgBouncer to try and reduce
the overhead of new connections on the database. I currently have
pgBouncer running on the same server as my postgres database but I was
wondering whether this is a recommended setup - are the performance
benefits of using a connection pooler overshadowed by the overhead of
running pgBouncer on the same server as the database?

How are other people using pgBouncer? E.g. on a separate server from the
database etc...?

Thanks in advance.


------_=_NextPart_001_01CB4343.6B86B8F4
Content-Type: text/html;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

xmlns:o=3D"urn:schemas-microsoft-com:office:office" =
xmlns:w=3D"urn:schemas-microsoft-com:office:word" =
xmlns:m=3D"http://schemas.microsoft.com/office/2004/12/omml" =
xmlns=3D"http://www.w3.org/TR/REC-html40">


charset=3Dus-ascii">









style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif" ;
color:#1F497D'>I have pgbouncer running on the same server, and I get =
over 2000
calls to a php page per minute.



style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif" ;
color:#1F497D'>Each call does inserts data digests into partitioned =
tables.



style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif" ;
color:#1F497D'>I also have a multi-threaded daemon connected to the same
database running background operations on the data coming =
in.



style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif" ;
color:#1F497D'>Works flawlessly.



style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif" ;
color:#1F497D'>BTW, 20 connections is not a heavy load at =
all.



style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif" ;
color:#1F497D'>In my application, pgbouncer has opened about 60 backends =
to
handle the cases where I have a high oncurrency of data coming in at =
once, but
usually the # non-idle connections is < 10.



style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif" ;
color:#1F497D'> 



style=3D'font-size:11.0pt;font-family:"Calibri","sans-serif" ;
color:#1F497D'> 



0in 4.0pt'>



0in 0in 0in'>

style=3D'font-size:10.0pt;font-family:"Tahoma","sans-serif"' >From:=
style=3D'font-size:10.0pt;font-family:"Tahoma","sans-serif"' >
pgsql-admin-owner@postgresql.org =
[mailto:pgsql-admin-owner@postgresql.org] On
Behalf Of
Kieren Scott

Sent: Monday, August 23, 2010 8:38 AM

To: pgsql-admin@postgresql.org

Subject: [ADMIN] pgBouncer for connection =
pooling







 



style=3D'font-size:10.0pt;font-family:"Tahoma","sans-serif"' >Hi,



I have a web-based application (drupal) which uses PHP to make =
connections to a
back-end postgresql 8.3 server. The application and database are on =
separate servers,
but as we can get 20+ concurrent connections on the database I've looked =
at
pgBouncer to try and reduce the overhead of new connections on the =
database. I
currently have pgBouncer running on the same server as my postgres =
database but
I was wondering whether this is a recommended setup - are the =
performance
benefits of using a connection pooler overshadowed by the overhead of =
running
pgBouncer on the same server as the database?



How are other people using pgBouncer? E.g. on a separate server from the
database etc...?



Thanks in advance.











------_=_NextPart_001_01CB4343.6B86B8F4--

Re: pgBouncer for connection pooling

am 24.08.2010 12:39:58 von Kieren Scott

--_386017ce-98b3-4bf1-93a1-200d3922c5be_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable


Thanks Benjamin.
Most of the time the database only has 5-6 connections=2C however we occasi=
onally get a flood of connections which can mean 60+ connections (when a co=
mpany email is sent out with a link to a web page)=2C so I'm looking to han=
dle these spikes in connections as best I can :-)

Kieren

Subject: Re: [ADMIN] pgBouncer for connection pooling
Date: Mon=2C 23 Aug 2010 22:15:34 -0600
From: kraj@servoyant.com
To: kierenscott@hotmail.com=3B pgsql-admin@postgresql.org
















I have pgbouncer running on the same server=2C and I get over 2000
calls to a php page per minute.

Each call does inserts data digests into partitioned tables.

I also have a multi-threaded daemon connected to the same
database running background operations on the data coming in.

Works flawlessly.

BTW=2C 20 connections is not a heavy load at all.

In my application=2C pgbouncer has opened about 60 backends to
handle the cases where I have a high oncurrency of data coming in at once=
=2C but
usually the # non-idle connections is < 10.

=20

=20







From:
pgsql-admin-owner@postgresql.org [mailto:pgsql-admin-owner@postgresql.org] =
On
Behalf Of Kieren Scott

Sent: Monday=2C August 23=2C 2010 8:38 AM

To: pgsql-admin@postgresql.org

Subject: [ADMIN] pgBouncer for connection pooling





=20

Hi=2C



I have a web-based application (drupal) which uses PHP to make connections =
to a
back-end postgresql 8.3 server. The application and database are on separat=
e servers=2C
but as we can get 20+ concurrent connections on the database I've looked at
pgBouncer to try and reduce the overhead of new connections on the database=
.. I
currently have pgBouncer running on the same server as my postgres database=
but
I was wondering whether this is a recommended setup - are the performance
benefits of using a connection pooler overshadowed by the overhead of runni=
ng
pgBouncer on the same server as the database?



How are other people using pgBouncer? E.g. on a separate server from the
database etc...?



Thanks in advance.



=

--_386017ce-98b3-4bf1-93a1-200d3922c5be_
Content-Type: text/html; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable






Thanks Benjamin.
Most of the time the database only has 5-6 connections=
=2C however we occasionally get a flood of connections which can mean 60+ c=
onnections (when a company email is sent out with a link to a web page)=2C =
so I'm looking to handle these spikes in connections as best I can :-)
<=
br>Kieren


Subject: Re: [ADMIN] pgBouncer for=
connection pooling
Date: Mon=2C 23 Aug 2010 22:15:34 -0600
From: kra=
j@servoyant.com
To: kierenscott@hotmail.com=3B pgsql-admin@postgresql.or=
g




">











alibri'=2C'sans-serif'=3B color: rgb(31=2C 73=2C 125)=3B">I have pgbouncer =
running on the same server=2C and I get over 2000
calls to a php page per minute.



alibri'=2C'sans-serif'=3B color: rgb(31=2C 73=2C 125)=3B">Each call does in=
serts data digests into partitioned tables.



alibri'=2C'sans-serif'=3B color: rgb(31=2C 73=2C 125)=3B">I also have a mul=
ti-threaded daemon connected to the same
database running background operations on the data coming in.



alibri'=2C'sans-serif'=3B color: rgb(31=2C 73=2C 125)=3B">Works flawlessly.=



alibri'=2C'sans-serif'=3B color: rgb(31=2C 73=2C 125)=3B">BTW=2C 20 connect=
ions is not a heavy load at all.



alibri'=2C'sans-serif'=3B color: rgb(31=2C 73=2C 125)=3B">In my application=
=2C pgbouncer has opened about 60 backends to
handle the cases where I have a high oncurrency of data coming in at once=
=2C but
usually the # non-idle connections is <=3B 10.



alibri'=2C'sans-serif'=3B color: rgb(31=2C 73=2C 125)=3B"> =3B p>

alibri'=2C'sans-serif'=3B color: rgb(31=2C 73=2C 125)=3B"> =3B p>

e none none solid=3B border-color: -moz-use-text-color -moz-use-text-color =
-moz-use-text-color blue=3B padding: 0in 0in 0in 4pt=3B">



=3B border-style: solid none none=3B border-color: rgb(181=2C 196=2C 223) -=
moz-use-text-color -moz-use-text-color=3B padding: 3pt 0in 0in=3B">

'Tahoma'=2C'sans-serif'=3B">From: =3B font-family: 'Tahoma'=2C'sans-serif'=3B">
pgsql-admin-owner@postgresql.org [mailto:pgsql-admin-owner@postgresql.org] =
On
Behalf Of
Kieren Scott

Sent: Monday=2C August 23=2C 2010 8:38 AM

To: pgsql-admin@postgresql.org

Subject: [ADMIN] pgBouncer for connection pooling







 =3B



ahoma'=2C'sans-serif'=3B">Hi=2C



I have a web-based application (drupal) which uses PHP to make connections =
to a
back-end postgresql 8.3 server. The application and database are on separat=
e servers=2C
but as we can get 20+ concurrent connections on the database I've looked at
pgBouncer to try and reduce the overhead of new connections on the database=
.. I
currently have pgBouncer running on the same server as my postgres database=
but
I was wondering whether this is a recommended setup - are the performance
benefits of using a connection pooler overshadowed by the overhead of runni=
ng
pgBouncer on the same server as the database?



How are other people using pgBouncer? E.g. on a separate server from the
database etc...?



Thanks in advance.






=

--_386017ce-98b3-4bf1-93a1-200d3922c5be_--