Create MySQL Database with Amazon RDS

Carl Hayes
Geek Culture
Published in
3 min readJun 9, 2021
Amazon RDS

What is RDS?

Amazon relational database service (RDS) is a service offered by AWS that database connectivity through the internet.

Why would you want RDS?
Because Amazon RDS takes over many of the difficult and tedious management tasks of a relational database:

When you buy a server, you get CPU, memory, storage, and IOPS, all bundled together. With Amazon RDS, these are split apart so that you can scale them independently. If you need more CPU, less IOPS, or more storage, you can easily allocate them. Amazon RDS manages backups, software patching, automatic failure detection, and recovery.

Automated backups can be configured when you need them, or you can manually create your own backup snapshot. You can use these backups to restore a database. The Amazon RDS restore process works reliably and efficiently.

You can use the database products you are already familiar with: MySQL, MariaDB, PostgreSQL, Oracle, Microsoft SQL Server. You can get high availability with a primary instance and a synchronous secondary instance that you can fail over to when problems occur.

In addition to the security in your database package, you can help control who can access your RDS databases by using AWS Identity and Access Management (IAM) to define users and permission. You can also help protect your databases by putting them in a virtual private cloud.

Now that the introduction is out of the way, lets get started!

Download MySQL Workbench

Please enter this link

https://dev.mysql.com/downloads/workbench/

  • Next, Select your operating system
  • Download x86 64bit version for windows or download x86 64 bit for MacOS
  • Install Workbench

Create a MySQL or MariaDB sample database

Visit AWS Management Console
Search for RDS
Create MySQL engine
Enable Free tier option
General-public-license
Use 5.8
Use db.t2.micro
20 GiB for allocated storage

Search for RDS
Create MySQL engine
Enable Free tier option
General-public-license
Use 5.8
Use db.t2.micro
20 GiB for allocated storage

Settings

DB Instance Identifier: purpledb

Master Username: admin

Master PW: mypassword

Select Next

Network & Security

Select VPC: Default

Subnet Group: Default

Public Accessible: Yes

Create new VPC SG: Be sure your SG allows inbound traffic to port 3306 for your IP.

Database Options

Database Name: TestDB

Port: 3306

DB parameter group: (Use default)

Option Group : (use default)

IAM DB Auth: Disable

(Skip Encryption)

Backup

7 day retention
No Pref
Enable auto minor upgrade

Deletion Protection
Create DB.

(takes about 4–5 min to create)

Copy endpoint

Connect to DB using the MySQL Workbench

Enter hostname, port, username and Password.

Select Ok and wait for the database to finish connecting.

If you’ve made it this far to the tutorial, congratulations! We’ve successfully created a RDS database and connected to it via MYSQL Workbench.

Sincerely,

Carlintheclouds

--

--

Carl Hayes
Geek Culture

An avid techie, hip-hop music enthusiast and photo taker. If it involves a terminal, there is a high chance you will find me in it.