RE: Cannot connect to local server

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thanks, Miles!

But actually I have PHP 5.0.2 + MySQL 4.1.9 + mysqli + PEAR::DB latest
installed on the server.

I have spent some weeks struggling with connection and charset problems. But
today I finally solved all these issues except one thing that seems to be a
bug of PEAR::DB package.

The problem is that I CAN connect using 

mysqli://user:pass@xxxxxxxxxxx/dbname

connection string and CANNOT connect using

mysqli://user:pass@localhost/dbname

(privileges/passwords ok, don't worry)

In the last case DB still raises the error message saying:

"Can't connect to local MySQL server through socket '' (111)"
(notice '')

Default socket /var/lib/mysql/mysql.sock does exist. Furthermore, I CAN
connect to localhost using mysqli_* functions. But DB package still shows me
errors when connecting to localhost (and all is OK when it is trying to
connect to example.com via TCP/IP).

Dear DB maintainers, should I report a bug?

> 
> 
> New version of MySQL, old PHP? possible password encryption mis-match?
> Check out:
> 
>          http://dev.mysql.com/doc/mysql/en/old-client.html
> 
> Regards - Miles
> 
> At 06:33 AM 2/10/2005, Denis Gerasimov wrote:
> 
> >Hello,
> >
> >I am trying to connect to MySQL using
> >
> >$mysqli = new mysqli("example.com", "user", "pass", "db");
> >
> >And access is ALWAYS denied
> >(I played around changing user name/pass/host - didn't help me at all)
> >
> >The thing is that I CAN connect to the db server using this user name and
> >password with my DB administration tool.
> >
> >Some background
> >1. MySQL and Apache + PHP are running on the same machine.
> >2. The user is allowed to connect from '%' (everywhere)
> >3. Connecting to localhost fails too (saying "cannot connect to
> socket...")
> >
> >What is going on?
> >
> >Best regards, Denis Gerasimov
> >Outsourcing Services Manager,
> >VEKOS, Ltd.
> >www.vekos.ru
> >
> >--
> >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


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux