From: | andy <andy(at)squeakycode(dot)net> |
---|---|
To: | Stephen Frost <sfrost(at)snowman(dot)net> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: Monitoring number of backends |
Date: | 2013-10-22 18:25:03 |
Message-ID: | 5266C2FF.2060101@squeakycode.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On 10/22/2013 12:59 PM, Stephen Frost wrote:
> Andy,
>
> * andy (andy(at)squeakycode(dot)net) wrote:
>> My website is about to get a little more popular. I'm trying to add
>> in some measurements to determine an upper limit of how many
>> concurrent database connections I'm currently using.
>
> PG is really *much* happier if you have only one backend per CPU in your
> system. The way to get there is by using a connection pooler like
> pg_bouncer and configuring it based on how many CPUs you have.
>
> pg_bouncer can also provide stats for you.
>
> Thanks,
>
> Stephen
>
Hum.. I had not thought of that. My current setup uses 40 max
connections, and I don't think I've ever hit it. I use apache and php,
and my db connections are not persistent.
If I did plugin pg_bouncer, is it worth switching my php from pg_connect
to pg_pconnect?
I'd bet plugging in pg_bouncer now while I'm not too busy would help me
grow in the long run, huh? I like the sound of that. Thanks!
-Andy
From | Date | Subject | |
---|---|---|---|
Next Message | Stephen Frost | 2013-10-22 18:50:23 | Re: Monitoring number of backends |
Previous Message | Stephen Frost | 2013-10-22 17:59:37 | Re: Monitoring number of backends |