I have taken sometime to lookup queries that are similar to my query but I could not find any useful solution.
I am trying to create an ODBC connection to MySQL database on my Web host Linux server. they have given me the right login details to use. In creating the connection from my local machine running Windows 7, I encountered the following error:
Connection Failed: [HY000] [MySQL][ODBC] 3.51 Driver]Access denied for user"MyDatabasename"#host-"MYLOCALMACHINE'S PUBLIC IP.net" (Using password: YES)
I am not sure why I am denied access on my local machine instead of the Web host server where am wishing to connect to and I don't seem to figure out what is wrong.The host should have been the company's host name not my local machine host Any hint or help will be appreciated. Thanks.
Related
I have a Go app running on App Engine, and a first generation CloudSQL instance running. I can connect to the SQL server from dev using a TCP connection, specifying the SQL server's IP. But I cannot connect from the deployed instance, using the CloudSQL driver.
Sample code
import (
"database/sql"
_ "github.com/ziutek/mymysql/godrv"
_ "google.golang.org/appengine/cloudsql"
)
if (dev) {
sql.Open("mymysql", "tcp:1.2.3.4:3306*database/user/pass")
} else {
sql.Open("mymysql", "cloudsql:project-id:instance-name*database/user/pass")
}
(Yes, I'm substituting database, user, pass, project-id, and instance-name for their correct values in my real code)
When running locally (via goapp serve) I can connect and query the database - everything works great.
However, when connecting from the deployed instance, I get the following error:
Received #1045 error from MySQL server: "Access denied for user 'readonly'#'localhost' (using password: YES)"
I have made sure that my App Engine instance is authorized (SQL > Instance > Access Control > Authorization), and I'm using the same user in both cases.
I've found something resembling my error message on the Diagnosing Issues with Cloud SQL Instances page, but the suggested solution is to connect with SSL if SSL is enabled (I have not enabled SSL for the server).
If you get an error message like:
ERROR 1045 (28000): Access denied for user 'root'#'1.2.3.4' (using password: YES)
when you connect, verify that you are using the correct
password and that you are connecting over SSL if the instance requires
it.
Seeing as how this has given me so much trouble, I also tried connecting via IP address from the App Engine instance, but the socket connection is denied.
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 "%"
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 am able to connect to the remote mysql database that is on a different domain that are in the same network, from the sql workbench(using servername.domain.com), but am unable to set up an ODBC connection using the same connection parameters.
I tried to connect using TCP/IP could not succeed. I get "Access denied for user" error, as its trying to connect using the current domain as the host. But the database server is on a different domain.How do we change the domain ?
I was not sure how to use named pipes, any help there would be appreciated.Thank you!
I've been trying to connect Excel to online mysql database.
Im using 5.1 DSN ODBC, gone through the process but when im establishing the connection of mysql and excel an error occured.
Connection Failed: [HY000] [MYSQL][ODBC 5.1 Driver]Access denied for user 'icafeown'#'118.252.49.9'(userpassword: YES)
I've been in the same questions like this but i cant establish the correct connection.
im using Cpanel for the domain and i already used Remote MySQL.
and the Database: Dropdown are empty.
Thank you.
Access denied means that you've successfully established a TCP connection to the MySQL server, but don't have appropriate permissions within MySQL to actually "log in" to the server.
Usually this is because of a mis-match on the 'host' portion of the MySQL user account. e.g. You may have created a someone#example.com account in MySQL, but your client's IP address cannot be reverse-lookuped to confirm that it is "example.com". MySQL only sees the IP you connect from, not the hostname. If your 118.252.49.9 can't be resolved to be 'example.com', you won't get it.
Same goes for connections on the same machine. You may have your someone#example.com MySQL account, but MySQL will see a connection come in from 127.0.0.1/localhost, which is NOT "example.com".