RE: [PHP-INSTALL] Problem by running mysql-connection in php-script
| From: | Michael Scappa | Date: | Thu, 02 Oct 2003 20:28:16 +0000 |
| Subject: | RE: [PHP-INSTALL] Problem by running mysql-connection in php-script | ||
| References: | 1 | Groups: | php.install |
| Request: | Send a blank email to php-install+get-11996@lists.php.net to get a copy of this message | ||
Ruprecht,
Make sure you have PHP pointing to the right location for the
mysql.sock. "locate mysql.sock". Sometimes its in the /tmp dir. If it is
in another location you can point to it specifically when you call
mysql_connect (refer to php.net for the exact string), or just change it
in your php.ini.
-Mike
-----Original Message-----
From: Ruprecht Helms [mailto:rhelms@mayn.de]
Sent: Thursday, October 02, 2003 4:10 PM
To: php-install@lists.php.net
Subject: [PHP-INSTALL] Problem by running mysql-connection in php-script
Hi,
I get this errormessage on all mysql-connections within a phpscript.
Warning: mysql_connect(): Can't connect to local MySQL server through
socket '/var/lib/mysql/mysql.sock' (2) in
/usr/local/apache/htdocs/controlling/liquiditaetsplan.php on line 20
The mysqld itselves starts properly on booting. What have I to configure
for correct connections within php. I installed php from the tarball.
Regards,
Ruprecht