#28098 [Fbk->Opn]: mysql_pconnect never kills threads
ID: 28098
User updated by: moreau at myrealbox dot com
Reported By: moreau at myrealbox dot com
-Status: Feedback
+Status: Open
Bug Type: MySQL related
Operating System: FreeBSD 5.2.1
PHP Version: 4.3.6
New Comment:
Yes, significantly.
Each script is successfully ended , so apache returns in
normal state ( minimal threads and process - as pointed in config )
after long timeout ( when pages aren't requested ). But MySQL has many
threads and no one of threads never die.
Previous Comments:
------------------------------------------------------------------------
[2004-04-21 19:19:51] gschlossnagle@php.net
mysql extension will create one connection per database
connect string per PHP interpreter context, i.e. one per
Apache thread or child. Is the number of connections
you are seeing exceeding your Apache thread count?
------------------------------------------------------------------------
[2004-04-21 19:17:21] moreau at myrealbox dot com
Description:
------------
mysql_pconnect every time generate new connection and never kill
previous.
As result - MySQL generate many threads for handling each query and
after too many connection hangs.
This never happened if use mysql_connect and mysql_close in each page.
I use apache2 . php compiled as module. apache use mpm=worker. I don't
know whether it problem in threadead apache or common problem in php
with mysql_pconnect.
mysql_pconnect in current state cannot be used for accessing to mysql.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=28098&edit=1
Thread (7 messages)