Connecting MySQL DB Instance present on AWS Cloud

Folks,

For creation of any Amazon RDS DB Instance (Free Tier), kindly visit this blog: Link

In this blog we will learn how to connect MySQL Database present on AWS Cloud.

Here is my MySQL DB Instance in “available” Status. Please note the End Point, which is basically the HOST.

1
RDS Dashboard

Step for adding new Inbound Rule for allowing connection on port 3306.

Select MySQL Instance & Click on “Instance Actions“->”See Details“.

2

After that click on “Security Groups“.

3

Now click on the “Inbound Rules” in Security Groups page.

4
Security Groups Page

Create a Inbound Rule for Type: MYSQL, Protocol: TCP , Port: 3306 Source: Anywhere. So that you can connect this instance from any machine. After creation of rule click on Save.

Security Group is basically allowing the connections on the port.

5

After Saving Inbound Rule. Go to RDS Dashboard.

1
RDS Dashboard

Now MySQL Instance is ready to connect & use it.


 

Steps for connecting MySQL Database: Using CMD

Install MySQL Server on your machine. Copy the location on bin folder in program files.

Also check your firewall settings for port 3306.

7

Also check the MySQL service is running properly or not.

6

Open Command Prompt: Use this command: cd <bin folder location> then Press Enter.

Example:  cd C:\Program Files\MySQL\MySQL Server 5.1\bin

Now you are in bin folder.

8

Use below command in cmd & it will ask for password.

mysql – h <host> -P <port> – u <username> – p

Where <host>: Your End Point, <post>:3306, <username>: Master username

9

Now we are connected to the MySQL DB Instance.

10


Steps for connecting MySQL Database: Using MySQL GUI

I’m using SQLyog GUI. Please provide below details.

01

Provide your password & test the connection.

02

Click on connect to connect the database.

03

Now we are connected to the MySQL DB Instance.


Thanks!

Happy Learning!

Advertisements

One thought on “Connecting MySQL DB Instance present on AWS Cloud

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s