Re: too many idle processes - Mailing list pgsql-general

From Soon-Son Kwon
Subject Re: too many idle processes
Date
Msg-id 20020522091259.A5186@mail.kldp.org
Whole thread Raw
In response to Re: too many idle processes  (Scott Marlowe <scott.marlowe@ihs.com>)
List pgsql-general
Thanks very much.
According to your description, my configuration
was broken.... My comments below....

--[snip]--
> > trace_notify = off
>
> This setting here:
>
> > max_connections = 64
>
> tells postgresql how many connections it can accept max.
>
> In Apache's httpd.conf file, the line
>
> MaxClients 90

For me, this was 512 because I just thought that higher value
can serve more clients.

> says how many clients the web server can accept connections from.  This is
> the maximum number of "child processes" apache will spawn.
>
> In php.ini we find the lines:
>
> pgsql.allow_persistent  =      On
> pgsql.max_persistent    =      2 #max persistant links per process
> pgsql.max_links        =       16 # max pers/non-pers links per process

For me, the old values were
pgsql.max_persistent    =      64
I thought this needs to be the same as /etc/postgresql/postgresql.conf

> We need to make sure that PHP/Apache don't try to open more than
> postgresql is configured for.
>
> You probably should increase the max_connections setting in
> postgresql.conf first, to at least 128 or 256.
>
> then, you need to set MaxClients * pgsql.max_persistant to be <
> max_connections.  Be sure and leave one or two spare connects for you to
> be able to get via a psql command line.
>
> note that if you are running >1 web server against one database server,
> you then have to have num_web_servers * MaxClients * pgsql.max_persistant
> < max_connections.

I changed all the values to fit your explanation and waiting for
user feedback for any error...

Thanks again for your kind information...
--
-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
           (o_             **WTFM**
(o_  (o_   //\
(/)_ (/)_  V_/_        http://kldp.org
-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*

pgsql-general by date:

Previous
From: "Miguel Carvalho"
Date:
Subject: Re: Mysterious locking problem
Next
From: Stephan Szabo
Date:
Subject: Re: ERROR: value too long for type character