RE: [PHP-DB] PHP Confused: Using wrong Unix Socket

2004-04-09 Thread Noah Davis
Thank you. I missed that setting obviously. The variable name is
mysql.default_socket.

-Original Message-
From: Jason Wong [mailto:[EMAIL PROTECTED] 
Sent: Thursday, April 08, 2004 11:21 PM
To: [EMAIL PROTECTED]
Subject: Re: [PHP-DB] PHP Confused: Using wrong Unix Socket

On Friday 09 April 2004 02:38, Noah Davis wrote:

 How can I get PHP to not get confused about which .sock file to use? 

php.ini

 Do I need to recompile PHP?

No.

-- 
Jason Wong - Gremlins Associates - www.gremlins.biz
Open Source Software Systems Integrators
* Web Design  Hosting * Internet  Intranet Applications Development *
--
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-db
--
/*
It is the quality rather than the quantity that matters.
- Lucius Annaeus Seneca (4 B.C. - A.D. 65)
*/

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-DB] PHP Confused: Using wrong Unix Socket

2004-04-08 Thread Noah Davis
My PHP installation seems to be confused as to where to find the MySQL
socket file.

 

The error I'm getting is: Warning: mysql_connect(): Can't connect to local
MySQL server through socket '/var/lib/mysql/mysql.sock' (2)

 

This isn't where the mysql.sock file is. It's at /tmp/mysql.sock.

 

This is possibly related to the fact that our MySQL installation has moved
since PHP was initially configured and that PHP is somehow still looking for
the old MySQL installation.

 

How can I get PHP to not get confused about which .sock file to use? Do I
need to recompile PHP?

 

In my searching around, the closest I've come to an explanation is at the
FAQs for PHP:

 

http://de3.php.net/manual/en/faq.databases.php#faq.databases.mysql.php5

 

which states:

 

Given the above, having multiple versions of the library can get messy. For
example, if you link mod_auth_mysql against one version and PHP against
another, and then enable both in Apache, you get a nice fat crash. Also, the
bundled library didn't always play well with the installed server version.
The most obvious symptom of this being disagreement over where to find the
mysql.socket Unix domain socket file.

 

But not sure what to do about this.

 

Thanks for any help you can offer!

 

Noah

 

Using:

PHP version 4.34.

MySQL version 4.1.1

Apache 1.3

 



Re: [PHP-DB] PHP Confused: Using wrong Unix Socket

2004-04-08 Thread Jason Wong
On Friday 09 April 2004 02:38, Noah Davis wrote:

 How can I get PHP to not get confused about which .sock file to use? 

php.ini

 Do I need to recompile PHP?

No.

-- 
Jason Wong - Gremlins Associates - www.gremlins.biz
Open Source Software Systems Integrators
* Web Design  Hosting * Internet  Intranet Applications Development *
--
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-db
--
/*
It is the quality rather than the quantity that matters.
- Lucius Annaeus Seneca (4 B.C. - A.D. 65)
*/

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php