Re: DB::connect / DB::isError

From: Date: Sat, 25 Oct 2003 09:46:20 +0000
Subject: Re: DB::connect / DB::isError
References: 1  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-8575@lists.php.net to get a copy of this message
Chris Paul wrote:
"Can't connect to the database: DB Error: insufficient permissions" (When I run Apache chrooted) or "Can't connect to the database: DB Error: connect failed" (When Apache is not chrooted)
IMO, the second error message tells the credentials used in DSN are insufficient. So the database server blocks the connect with the login information used. The first one should mean, that Apache + PHP can't connect to the database server, because you are running Apache chrooted. Well how come? Say you use MySQL as database backend: a connection can be made using tcp connect to the (if the default one used) port 3306 or through a socket. I'm not sure if such a socket always is needed/used or if there is a problem for the database server to run a process. Maybe the database server can't be run within the chroot. You could get more detailled error information when doing a var_dump($db); with $db is the variable you wanted to store the database connection object created by DB::connect() call. Hope that helps. Regards -- Dennis Sterzenbach http://www.darknoise.de/

« previous php.pear.general (#8575) next »