dimanche 18 mai 2014

Connexion à Amazon RDS MySql à distance - Stack Overflow


I've seen questions like this before but all the answers didn't work


I'm trying to connect to MySql on Amazon RDS from my computer, using MySql WorkBench, or HeidiSql or even the console Mysql.exe and i'm getting this error all the time:


ERROR 2003 (HY000): Can't connect to MySQL server on 'MY-SERVER-NAME' (10060)



  1. In the Security group of the instance I created a new Inbound rule that allows all traffic, and applied it, and still - same error.

  2. I have no active Firewall on my computer, and have good internet access

  3. I am able to access the DB from the Amazon EC3 server, there I am connecting using HeidiSql, and the exact same settings (host, username, password) is just not working on my computer


Thanks a lot


EDIT: Still, nothing is working. I'm pretty sure that my security groups is configured to allow outside connections, as can be seen on the next screenshot, there is another place with firewall rules? Screenshot of SecurityGroups




The 2003 error is the Access-Denied Error I would be willing to bet that you haven't configured the RDS to accept your IP address.


This can be done by going to DB Security Groups -> Click Default -> and add a new CIDR/IP range. I believe that if you set it to 0.0.0.0/0 it will accept all ip addresses




The security group settings are just firewall rules. If you can telnet on your configured MySQL port from the host you are having problems then you don't have the security group issue.


Chances are the MySQL grants are not allowing outside IPs. If you know the root user/password and you can use it to connect from your EC2 instance that works, make sure the user you are using to connect from outside has the right privileges. Here is the doc on how to add a new privilege or create a new user:


http://dev.mysql.com/doc/refman/5.1/en/grant.html http://dev.mysql.com/doc/refman/5.1/en/adding-users.html http://dev.mysql.com/doc/refman/5.0/en/access-denied.html




I use SQLyog for connecting to Amazon RDS from my machine.


You can refer this blog: http://blog.webyog.com/2009/11/06/amazon-rds-the-beginners-guide/



I've seen questions like this before but all the answers didn't work


I'm trying to connect to MySql on Amazon RDS from my computer, using MySql WorkBench, or HeidiSql or even the console Mysql.exe and i'm getting this error all the time:


ERROR 2003 (HY000): Can't connect to MySQL server on 'MY-SERVER-NAME' (10060)



  1. In the Security group of the instance I created a new Inbound rule that allows all traffic, and applied it, and still - same error.

  2. I have no active Firewall on my computer, and have good internet access

  3. I am able to access the DB from the Amazon EC3 server, there I am connecting using HeidiSql, and the exact same settings (host, username, password) is just not working on my computer


Thanks a lot


EDIT: Still, nothing is working. I'm pretty sure that my security groups is configured to allow outside connections, as can be seen on the next screenshot, there is another place with firewall rules? Screenshot of SecurityGroups



The 2003 error is the Access-Denied Error I would be willing to bet that you haven't configured the RDS to accept your IP address.


This can be done by going to DB Security Groups -> Click Default -> and add a new CIDR/IP range. I believe that if you set it to 0.0.0.0/0 it will accept all ip addresses



The security group settings are just firewall rules. If you can telnet on your configured MySQL port from the host you are having problems then you don't have the security group issue.


Chances are the MySQL grants are not allowing outside IPs. If you know the root user/password and you can use it to connect from your EC2 instance that works, make sure the user you are using to connect from outside has the right privileges. Here is the doc on how to add a new privilege or create a new user:


http://dev.mysql.com/doc/refman/5.1/en/grant.html http://dev.mysql.com/doc/refman/5.1/en/adding-users.html http://dev.mysql.com/doc/refman/5.0/en/access-denied.html



I use SQLyog for connecting to Amazon RDS from my machine.


You can refer this blog: http://blog.webyog.com/2009/11/06/amazon-rds-the-beginners-guide/


0 commentaires:

Enregistrer un commentaire