Bug #4223 Updated: PHP calls MySQL with apache user instead of connected user
| From: | derick@php.net | Date: | Sun, 26 May 2002 17:40:39 +0000 |
| Subject: | Bug #4223 Updated: PHP calls MySQL with apache user instead of connected user | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-8591@lists.php.net to get a copy of this message | ||
ID: 4223
Updated by: derick@php.net
Reported By: louis@sitebysite.nl
-Status: Analyzed
+Status: Bogus
Bug Type: MySQL related
Operating System: RedHat 6.1
PHP Version: 4.0 Release Cand
New Comment:
Thank you for taking the time to report a problem with PHP.
Unfortunately your version of PHP is too old -- the problem
might already be fixed. Please download a new PHP
version from http://www.php.net/downloads.php
If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.
Previous Comments:
------------------------------------------------------------------------
[2002-04-27 13:26:54] jimw@php.net
this isn't a feature request.
------------------------------------------------------------------------
[2000-08-08 22:30:25] waldschrott@php.net
I don´t kwno any way, moving to feature request
------------------------------------------------------------------------
[2000-07-30 17:07:23] zak@php.net
User response:
"As far as I can gather it has something to do with the
wait_timeout of MySQL. This was set pretty low. I think
the persistent connections outlived the connections on the
database side during quiet periods. The error doesn't
seem to appear if I up this timeout or bring down the
life span of the apache child processes. Is there a
way to set a timeout on the persistent connections
on the php side? That would enable one to match it
against the MySQL timeout and make sure it never happens."
------------------------------------------------------------------------
[2000-07-30 13:52:19] zak@php.net
** Warning - uneducated guess **
This seems like it might be a mysql configuration issue.
Please review the MySQL documentation on performance - try increasing
the max number of connections, etc...
Also, what user does you web server run as - www by chance?
------------------------------------------------------------------------
[2000-04-24 03:04:48] louis@sitebysite.nl
This is hard to reproduce, but every once in a while PHP tries to use
the
user running apache instead of the user specified in mysql_pconnect()
to
query MySQL. So after a pconnect with user X, you get a "access
denied
for user www" from the query. Our config is a dual-processor webserver
and dual-processor MySQL machine. With low traffic, it does not occur.
It also appears to occur only when using write locks on tables, but I
can't positively verify that - only that I haven't seen it happen on
sites
not using table locks, yet.
PHP configured with:
./configure --with-apxs=/usr/local/apache/bin/apxs --with-mysql=/usr
--enable-track-vars --with-gd=../gd1.4 --with-ttf --without-pcre-regex
--with-mm=../mm-1.0.12 --enable-inline-optimization --disable-debug
--with-recode --with-t1lib --with-dbase
Also running the Zend optimizer for RC1.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=4223&edit=1