php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #10276 persistent connections overload
Submitted: 2001-04-10 19:18 UTC Modified: 2001-08-03 18:59 UTC
From: zeekamotay at hotmail dot com Assigned:
Status: Not a bug Package: PostgreSQL related
PHP Version: 4.0.4pl1 OS: linux 2.2
Private report: No CVE-ID: None
 [2001-04-10 19:18 UTC] zeekamotay at hotmail dot com
Using Apache 1.3.19, PHP 4.0.4pl1, PgSQL 7.0.3. Web server is RedHat 7.0, PgSQL server is RedHat 6.2.

This seems to be the same issue as #8769 and #9185, but I can't edit those, so I'll add a new entry since my comments may be helpful.

PHP is apparently not always re-using already opened idle persistent connections. Even though there are only a handful of non-idle connections running at any one time, the max (currently 256) number of connections eventually gets hit and the database will refuse new connections even though it's hardly doing anything.

Right now, my web server has 22 Apache processes running, yet there are 55 Postgres processes running, only two of which are not idle.

My installation was already using a static module, so I tried compiling all of Apache as one big static, but that had no effect.

Stopping and restarting Apache will clear the idle sessions.

I turned off Apache's keepalive feature, and that seems to have helped somewhat, since the Apache child processes now don't stick around so long. However, doing that is a performance hit I don't want to take, and it still doesn't explain how I can have more Postgres processes than Apache processes.

Any help is greatly appreciated. Long live PHP!

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-08-03 15:52 UTC] sniper@php.net
One bug report per bug please. 
(You can EDIT the old ones, you know..)

I'm bogusing this one now. In the future, for this
bug, modify bug report #12558 
 [2001-08-03 18:59 UTC] zeekamotay at hotmail dot com
Er, whoops. I totally forgot that I had already reported this issue. (Hey, it was 4 months ago!) My apologies.
 
PHP Copyright © 2001-2019 The PHP Group
All rights reserved.
Last updated: Mon May 27 02:01:26 2019 UTC