0

I'm new to Amazonaws. created a Mysql DB instance on RDS. with a free account.

Now when trying to connect from local machine by MySqlWorkbench. below is the endpoint of my db instance XXXXXXXXXX.XXXXX.us-west-2.rds.amazonaws.com:3306 using the same as above as hostname and port on local still not able to connect.

Does it has anything to do with the region? I mistakenly selected Oregon(west) region whereas I'm in New Jersey(east)

Kara
  • 6,115
  • 16
  • 50
  • 57
  • 2
    did you check the security group for that instance? – cool Oct 03 '15 at 22:10
  • its a free trial account. I don't have any security group. "Your account does not support the EC2-Classic Platform in this region. DB Security Groups are only needed when the EC2-Classic Platform is supported. Instead, use VPC Security Groups to control access to your DB Instances. Go to the EC2 Console to view and manage your VPC Security Groups. For more information, see AWS Documentation on Supported Platforms and Using RDS in VPC." –  Oct 03 '15 at 22:11
  • `Instead, use VPC Security Groups to control access to your DB Instances` Did you do that? – Eric J. Oct 03 '15 at 22:13
  • every server on amazon aws has a security group. you can see in your instance information panel under netword and security part – cool Oct 03 '15 at 22:14
  • `Does it has anything to do with the region? I mistakenly selected Oregon(west) region whereas I'm in New Jersey(east)` No. Doesn't matter. – Eric J. Oct 03 '15 at 22:14
  • @cool apologies for my ignorance. Yes I do see the security group. and its configuration for outbound is ALL everywhere. for inbound its as follows Type Protocol Port Range Source MYSQL/Aurora TCP 3306 170.34.104.13/32 what should I add here? My ip ? –  Oct 03 '15 at 22:20
  • 170.34.104.13 is that your IP. if not you should change it to yours. – cool Oct 03 '15 at 22:23
  • thanks @cool I added the ip shown in my mac network tab in system preference but it didn't work. So I added anywhere in the security group inbound configuration, I'm able to connect now. right now I'm just doing hands on on AWS I'lll change the configuration later....thanks for you advice. –  Oct 04 '15 at 08:40

2 Answers2

0

There are two primary solution candidates.

Firewall

Go into VPC Security Groups (I guess that is where you control the firewall. My paid account uses Security Groups). Ensure that your public IP (and only your public IP) is allowed through the firewall.

MySQL Permissions

On the local machine, check that your remote machine is allowed to connect. It's also possible that MySQL is not running. You'll discover if that is the case while checking permissions locally.

Community
  • 1
  • 1
Eric J.
  • 147,927
  • 63
  • 340
  • 553
0

Thanks a lot guys, Following are the steps to correct.

Go to MySQL instance. ] click on security Icon. Click on security Group at bottom click on Inbound Click Edit Add your IP for MYSQL db or any DB instance you have.