How to create an AWS RDS database instance

Overview

First, let's discuss Amazon Relational Databases and Database Instances below:

The Amazon Relational Database is:

  • Basic building blocks to create database instances
  • Platform as a Service (PaaS) Cloud Solution
  • Used for structured relational data
  • Used to deploy and scale user-created databases with high availability

The Database Instances are:

  • Isolated cloud database resource environment
  • Contain multiple user-defined and created databases
  • Can be scaled up or down based on computing or memory requirements
  • Supports MySQL, Oracle, MariaDB, Amazon Aurora DB, and Microsoft SQL engines

How to create an RDS DB instance in AWS

First step in creating an RDS Instance on AWS
First step in creating an RDS Instance on AWS
  • Click "Create database."
  • We select our preferred database engine or engine type. For this, we choose PostgreSQL. Please note that we can use AWS's configurations by selecting the "Standard create" option.
Selecting the desired database creation method and Engine option
Selecting the desired database creation method and Engine option
  • In this case, select the "Free tier" option.

Availability/Durability

Leave this as default. It is essential to state that availability ensures that we do not experience downtimes when there is an issue with our database instance in a particular region.

Note: Setting up availability is not a feature of the free tier database template

Set up and Configure the Database Instance

Now, we apply our desired security settings to our database instance:

  • Add the name of the database instance identifier, a master username, and a password for security.
Setting up database instance credentials
Setting up database instance credentials
  • Leave the "Instance configuration" as default as this is preconfigured.
  • Choose desired storage type.
Choosing desired storage type
Choosing desired storage type

Note: Autoscaling should be selected to ensure that the database uses only the resources it needs.

Database connectivity

Setting up database connectivity options
Setting up database connectivity options

To configure connectivity for the database instance,

  • We can choose public access if we want to access the database instance over the internet.
  • We can choose private access if we want the instance accessible only by selected devices and IP addresses in the private cloud.
  • Choose an availability zone to ensure low latency.
  • Set the "Database authentication" type to use a password.
Choosing the preferred database authentication type.
Choosing the preferred database authentication type.

Additional Configuration

Specify the name of the database as chosen previously. This section enables us to set up configurations for backup and recovery, logging, and monitoring.

We can leave this as default since we do not desire to activate the options shown.

Setting up additional configurations
Setting up additional configurations
  • Select "deletion protection" to prevent the database instance from being accidentally deleted.
Activating deletion protection
Activating deletion protection
  • Click "Create database" and wait a few minutes for the database instance to be created.
Create database
Create database

Please wait for a few moments for the database to be created:

  • Click the database instance identifier to navigate to the database dashboard. In this case, it is"testdatabase-1."

We should be able to monitor and connect to our database using the instance endpoint found in the connectivity section of the instance.

Database instance dashboard.
Database instance dashboard.