I have a phpMyAdmin with MySQL on a linux remote machine to which I can connect with no problem with a browser.
But when I am trying to connect a DB in MySQL from a .NET program in my machine, I am getting an error message:
Authentication to host 'theIpNumber' for user 'newUserName' using method 'mysql_native_password' failed with message: Access denied for user 'newUserName'#'myMachineName' (using password: YES)
I tried to configured it like it is explained here: http://www.devside.net/wamp-server/accessing-mysql-or-phpmyadmin-from-outside
creating a new user with password in phpMyAdmin and changing the config.inc.php
Then in my app.config I have the connection string with:
connectionString="server=theIpNumber;UserId=newUserName;Password=newUserPassword;database=theDB"
But I am still getting the same error message when I run my program. Any idea how to solve this?
Finally I solved it adding in phpMyAdmin another user with the same name "newUserName" and password, and with the host value "%"
Related
I'm trying to connect my NodeJS application to my remote MySQL Database, but it keeps giving me a 1045 error ('ER_ACCESS_DENIED_ERROR'). From the same workstation, I can connect to the same database through MySQL Workbench perfectly fine.
This leads me to think that the problem was with my NodeJS setup, but copying the database to a local setup and then connecting it, worked just fine. For the sake of testing, I made a DB user with host: %, and from my Node app, I connect to the IP address where the database is hosted. I'm hosting it on my own Centos 7 droplet with my workstation IP whitelisted.
The error message I get is:
"Access denied for user '[the test user I made]'#'[workstation ip]' (using password: YES)"
Any help is much appreciated!
The following error:
"Access denied for user '[the test user I made]'#'[workstation ip]' (using password: YES)"
Usually indicates a wrong password.
Check that you wrote down the correct password and fix it if need be.
Also good to read about at this point is: https://dev.mysql.com/doc/internals/en/authentication-method.html
Apparently (atleast I think) the password I used, had forbidden characters in it (not sure which ones). Generating a simpler password solved the issue!
I have set up a MySQL server on Debian Linux and need to access a database on this server via vb.net. I found some help on Code Project to download the connector.net library and build a class to access the MySQL database. However when I try to connect I get the authentication error below when attempting to establish a connection with the mysql server:
Authentication to host '192.168.68.47' for user 'root' using method 'mysql_native_password' failed with message: Access denied for user 'root'#'' (using password: YES)"} System.Exception
It seems that the library is appending the Windows workstation and domain to the user name and I am getting error. I tried using the root user with "#IPaddress" of the workstation, but it simply appended the workstation name and domain to this user. I also tried with another user besides root.
This is perfectly logic, because on your mysql server you need to Grant access to your host so it will be allowed to connect to, you can do it by following instructions in the following
Link
Also in the mysql configuration file, in your case : /etc/mysql/my.cnf you need to delete the line
bind-address = 127.0.0.1
This line will restrict all access from remote hosts, deleting it will allow access from remote hose which is what you want to do.
Hope this helps.
I'm unable to connect to Google Cloud SQL from my desktop mysql client. I am also unable to set the sql instance password in google console. It says "instance is busy". I was able to connect to the sql instance using this same command line few weeks ago. Now it's unclear why it is not allowing the same. I see a similar question being asked before but it does not have any resolution.
c:\mysql --host=xxx.xxx.253.xx --user=root --password
ERROR 1045 (28000): Access denied for user 'root'#'xxx.xxx.214.xxx' (using password: NO)
The reason I'm trying to connect from the command line is that my access to the same DB from GAE is also failing with the same error as below.
com.xxx store: java.sql.SQLException: Access denied for user 'root'#'localhost' (using password: YES)
This is the first time I'm trying to access the database from a GAE app. Any idea why the mysql client is not connecting and where I should look to troubleshoot?
Edit:
mysql client connection issue is resolved by upgrading to a newer mysql version (5.6.19). The GAE connection issue persists.
The jdbc url I use is
"jdbc:google:mysql://projid:sqlinstance/dbname?user=root&password=root"
The GAE connection issue was resolved by removing the password from the URL. The new jdbc
url is "jdbc:google:mysql://projid:sqlinstance/dbname?user=root".
I'm trying to connect to MySQL, using Sequel Pro, something I have done many times before. Host 127.0.0.1, username root, no password. I get the following message:
Unable to connect to host 127.0.0.1 because access was denied.
Double-check your username and password and ensure that access from your current location is permitted.
MySQL said: Access denied for user 'root'#'localhost' (using password: NO)
For what it's worth, I got this message after upgrading to a new Mac OS (Mavericks), realized that the server wasn't running, downloaded a new server (which is currently running), and tried again - but I had the same problem.
Make sure you are running MySql in background System Preferences -> Mysql -> Start MySql
Make sure you are able to connect to MySql through command line, if command line works, there is no reason why it should not work in SequelPro.
If problem still persists, try changing the 'root' password.
It happened to my in Mac. I went to system preferences -> MySQL -> Stopped the server, started it again, and it worked.
I've installed XAMPP. I had put up security barriers but as time went by I forgot my credentials and could no longer access the MySQL server through phpMyAdmin. I keep having the following error trying to enter phpMyAdmin:
1045 Cannot log in to the MySQL server.
I've edited C:\xampp\phpMyAdmin\config.inc to change my passwords but I had no success afterwards. I've altered the bit:
Authentication method (config, http or cookie based)
$cfg['Servers'][$i]['user'] = 'xxxxx' ;
$cfg['Servers'][$i]['password'] = 'yyyy' ;
I've run the MySQL resetroot batch file without success.
I've changed the default ports on my Apache and Mysql at the localhost a couple weeks ago and now I can't access mysql.exe.
Can't connect to MYSQL service on 'localhost'(10061).
How can I change the default localhost port?
Did you take a look here?
After installing a local server and trying to access phpMyAdmin, you could possibly encounter the error: #1045 Access Denied for user 'root'#'localhost' (using password: YES).
If root#localhost wasn't granted the necessary rights to access the database or you provided the wrong password, you will then encounter this error.
Following this tutorial will help guide you on bypassing this error, for any local host server using phpMyAdmin.