Search Postgresql Archives

Re: Apache + PHP + Postgres Interaction

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 24.08.2007 12:56, Bill Moran wrote:
How did you verify that? It will spawn a new connection silently, if the old got dropped. Did you really verify your logs, that you don't get more new connections than Apache spawns workers? This might not be noticeable for you, if you are running Apache. In a FCGI environment where you have a fixed amount of workers, you notice new connections, as there should not be any.

As I stated in the other reply to an email that looked similar to this
one -- I'm not sure I understand the behaviour you're trying to describe.

Persistent connections get randomly dropped. Now there is either an Apache worker with mod_php or and FCGI child that has lost its connection to the database. On the next request that is processed by this child / worker it will notice that it has lost its connection and will create a new one. This behaviour might depend on pgsql.auto_reset_persistent.

When using a classical Apache config (that is a non-threaded MPM) Apache does adjust its number of workers dynamically, so it's natural that more database connections are created under load and are dropped again after some idle time. That is why it might be hard to verify that you are not hit by this bug, as in your environment there is a native fluctuation.

In an FCGI environment however, you will notice this immediatelly, as the number of childs / workers is usually fixed and something must be broken if connection come and go.


--
Regards,
Hannes Dorbath

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux