I don't know whether this is related or not, but I've also found that since
upgrading to PHP 4.2.0 it is impossible to get mysql_connect() to connect
via a UNIX socket. No matter whether I specify a socket manually or not, it
always connects via TCP.

I have 4.1.2 running on a different server, and even just specifying
"localhost" for the database host, automatically connects via UNIX socket.

"Derick Rethans" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Hey Zak,
>
> I think this is a nice thing for 4.2.1. I can reproduce it. I hope
> somebody can investigate this before friday (RC1 of 4.2.1 is scheduled
> then).
>
> Derick
>
> ---------- Forwarded message ----------
> Date: 23 Apr 2002 19:50:29 -0000
> From: [EMAIL PROTECTED]
> To: [EMAIL PROTECTED]
> Subject: Bug #16768: mysql_connect("localhost",
>      ...) doesn't connect to localhost!
>
> From:             [EMAIL PROTECTED]
> Operating system: Red Hat Linux 7.2
> PHP version:      4.2.0
> PHP Bug Type:     MySQL related
> Bug description:  mysql_connect("localhost", ...) doesn't connect to
localhost!
>
> After upgrading from PHP 4.1.2 to PHP 4.2.0, MySQL connections fail with
> this error:
>
> Warning: Access denied for user: '[EMAIL PROTECTED]'
>
> Apparently, it is trying to connect to 'my.fully.qualified.name' instead
> of 'localhost' as before. This seems wrong because my mysql_connect() call
> uses 'localhost' as the host name:
>
> mysql_connect("localhost", "username", "password");
>
> I can work around this by changing all my MySQL grants from
> 'username'@'localhost' to 'username'@'my.fully.qualified.name', but that
> seems unnecessary; this should be fixed in PHP.
>
> BTW, I've used the same above mysql_connect() call since the PHP 3.x days
> and it's always worked fine, until now.
>
>
> My PHP configure line:
> ./configure --with-apache=../apache_1.3.24 --enable-track-vars \
>   --with-mysql --with-zlib --with-gd
>
> All PHP configuration settings are defaults. (i.e. php.ini =
> php.ini-dist)
>
> Apache version is 1.3.24. MySQL version is 3.23.49a.
> --
> Edit bug report at http://bugs.php.net/?id=16768&edit=1
> --
> Fixed in CVS:        http://bugs.php.net/fix.php?id=16768&r=fixedcvs
> Fixed in release:    http://bugs.php.net/fix.php?id=16768&r=alreadyfixed
> Need backtrace:      http://bugs.php.net/fix.php?id=16768&r=needtrace
> Try newer version:   http://bugs.php.net/fix.php?id=16768&r=oldversion
> Not developer issue: http://bugs.php.net/fix.php?id=16768&r=support
> Expected behavior:   http://bugs.php.net/fix.php?id=16768&r=notwrong
> Not enough info:     http://bugs.php.net/fix.php?id=16768&r=notenoughinfo
> Submitted twice:     http://bugs.php.net/fix.php?id=16768&r=submittedtwice
>



-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to