Re: Re: Bug #16768: mysql_connect("localhost", ...) doesn't connect to localhost! (fwd)
| From: | James E. Flemer | Date: | Wed, 24 Apr 2002 14:06:16 +0000 |
| Subject: | Re: Re: Bug #16768: mysql_connect("localhost", ...) doesn't connect to localhost! (fwd) | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-83258@lists.php.net to get a copy of this message | ||
On Wed, 24 Apr 2002, Daniel Swarbrick wrote:
> Yes, I have MySQL running all the time. I noticed this in
> ext/mysql/config.m4 :
>
> MYSQL_SOCK=/tmp/mysql.sock
> for i in \
> /var/run/mysqld/mysqld.sock \
> /var/tmp/mysql.sock \
> /var/lib/mysql/mysql.sock \
> /var/mysql/mysql.sock \
> /Private/tmp/mysql.sock \
> ; do
> if test -r $i; then
> MYSQL_SOCK=$i
> fi
> done
>
> ...which doesn't quite match my socket at /var/run/mysql/mysql.sock -
> defaulting to /tmp/mysql.sock.
Is there any problem with doing something like this:
/path/to/mysql_config --socket
in ./configure to get the socket path? I think that this
way is a little more likely to get it right in the case
that mysqld is not running at the time of configure. I
suppose we do not even know the "/path/to" in configure
when using the bundled mysql libs tho huh?
-James