List:General Discussion« Previous MessageNext Message »
From:shawn l.green Date:January 13 2014 8:47pm
Subject:Re: Access denied for user 'root'@'localhost' (using password: YES)
on mysql admin
View as plain text  
Hello Reindl,

On 1/13/2014 3:01 PM, Reindl Harald wrote:
> *your application* is connecting to mysql
> *your application* is using a hostname
> *your application* *may* use 127.0.0.1
> *your application* should use localhost to *connect to the databse*
> *your application* can only use TCP *if there is* a *mysql user* with *that host*
>
> http://dev.mysql.com/doc/refman/5.5/en/can-not-connect-to-server.html
>


... snip ...

The problem is, his other clients (his php page,his eclipse environment) 
is where he has problems making the connection from. His direct 
connection (using the mysql command line client) is having no problems.

So, the issues are:
* Why is a client connection, from the same host as the mysqld server, 
initiated from his PHP code failing to connect?

* Why is a client connection, from the same host machine as his mysqld 
server, initiated from his Eclipse programming tool failing to connect?


We are not saying he is using HTTP commands to log into his database.
We have clarified that both his client and his server are on the same host.

My last advice is that the password he is providing through his other 
clients must be incorrect. I even suggested that he may be validating 
his account on one instance but his tools are attempting to connect to a 
different instance.

And whether I say
    mysql -u root -h localhost  (via Unix socket)

or I say
    mysql -u root -h 127.0.0.1  (via TCP socket)

they may /both/ be reported as 'localhost' in the error message because 
of how the reverse DNS lookup happens during the user authentication 
process and the contents of his local /etc/hosts file.
http://dev.mysql.com/doc/refman/5.6/en/connection-access.html


Does that give you a better image of the current problem?
-- 
Shawn Green
MySQL Senior Principal Technical Support Engineer
Oracle USA, Inc. - Hardware and Software, Engineered to Work Together.
Office: Blountville, TN
Thread
Access denied for user 'root'@'localhost' (using password: YES) onmysql adminÉrico13 Jan 2014
  • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminReindl Harald13 Jan 2014
    • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminErick Ocrospoma13 Jan 2014
      • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminÉrico13 Jan 2014
        • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminErick Ocrospoma13 Jan 2014
          • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminErick Ocrospoma13 Jan 2014
            • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminÉrico13 Jan 2014
              • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminErick Ocrospoma13 Jan 2014
                • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminÉrico13 Jan 2014
                  • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminshawn l.green13 Jan 2014
                    • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminÉrico13 Jan 2014
                      • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminReindl Harald13 Jan 2014
                        • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminshawn l.green13 Jan 2014
                          • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminReindl Harald13 Jan 2014
    • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminÉrico13 Jan 2014
      • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminReindl Harald13 Jan 2014
Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminÉrico14 Jan 2014
  • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminClaudio Nanni15 Jan 2014
    • Re: Access denied for user 'root'@'localhost' (using password: YES)on mysql adminÉrico16 Jan 2014