0% found this document useful (0 votes)
25 views4 pages

AWS RDS Database Setup Guide

The document provides an overview of databases, their importance, and the challenges associated with on-premises databases. It introduces AWS RDS (Relational Database Service) as a fully managed cloud database solution that simplifies database management and is based on a pay-as-you-go model. The document also outlines steps for setting up a MySQL database using RDS and includes practice SQL queries for users to execute.

Uploaded by

Abhisek Sahoo
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
25 views4 pages

AWS RDS Database Setup Guide

The document provides an overview of databases, their importance, and the challenges associated with on-premises databases. It introduces AWS RDS (Relational Database Service) as a fully managed cloud database solution that simplifies database management and is based on a pay-as-you-go model. The document also outlines steps for setting up a MySQL database using RDS and includes practice SQL queries for users to execute.

Uploaded by

Abhisek Sahoo
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd

=========

AWS RDS
=========

1) What is Database

2) Why we need database

3) On-Prem Database & Challenges

4) What is RDS & Why

5) RDS Setup

6) Connecting with RDS DB Server using MySQL Workbench

7) Conclusion

===================
What is Database ?
===================

Database : It is a software which is used to store the data permanently.

Whatsapp Application -------------> Database

- Text msgs
- Audio files
- Video files
- Documents

=> Every s/w application will use database to store the data permanently.

=> Software applications will use SQL to communicate with databases.

=> SQL stands for Structured Query Language.

SQL
Application ------------> Database

=> Using SQL we can perform CRUD operations in the database.

C -> Create
R -> Retrieve
U -> Update
D -> Delete

=> We have several databases in the market

- Oracle
- MySQL
- SQLServer
- PostGres ....

=> The above databases are called as Relational Databases.

=> Relational databases will store the data using tables.


=> Table represents data using Rows and columns.

=================
Database Setup
=================

=> We can setup database in 2 ways

1) On-Prem Database

2) Cloud Database

==================================
Challenges with On-Prem Database
==================================

1) Purchase DB server license

2) Install DB Server s/w

3) Security

4) Network

5) Availability

6) Scalability

7) Backup

8) Adminstration (DBA)

=> To overcome above challenges it is highly recommended to use Cloud Database.

=> If we use cloud database then cloud provider will manage database server for us.

=> AWS RDS service providing cloud databases

=> RDS stands for relational database service in AWS cloud

=> RDS is used to create & manage relational databases

=> RDS is a fully managed service in AWS cloud.

=> RDS works based on "pay as you go" model.

=============
RDS Lab Task
=============

Step-1 : Create MySQL DB Server using RDS

Step-2 : Enable MySQL :: 3306 port number in Security Group Inbound Rules

Step-3 : Test MySQL DB Connection using MySQL Workbench software (client s/w)

Step-4 : Execute some SQL queries for practice (optional)


Step-5 : Delete RDS instance to avoid billing.

============================
MySQL DB Creation Steps
============================

Creation method : Standard Create

Engine Type : MySQL

Templates: Free Tier

DB instance identifier : ashokit-db-instance

public access : Yes

Database options : Initial DB name : sbidb

====================
Database Details
====================

DB Endpoint
DB username
DB password
DB port

Note : Using above details we can check database connectivity.

=> Once connectivity is successful then we will share database details with
developmen team.

Master username :

Master password :

Endpoint :

Note: Use MySQL Workbench and test database connectivitity. If you are able to
connect that means your RDS Setup is successful.

============================
SQL Queries For Practice
============================

=> Execute below sql queries using workbench

show databases;
use sbidb;
show tables;

## table creation query


create table emp(
eid int(10),
ename varchar(100),
esal int(10)
);

## retrieve records query


select * from emp;

## insert query
insert into emp values(1, 'john', 1000);
insert into emp values(2, 'smith', 2000);

select * from emp;

#### note: once practice completed, delete RDS instance ######

===========
Assigment
===========

1) Connect with RDS DB Server using EC2 Linux VM and execute above sql queries.

### Springboot with RDS Integration : [Link]

Common questions

Powered by AI

Deleting an RDS instance after practice sessions is crucial for cost management, as AWS RDS operates on a 'pay as you go' model, where users are billed for the resources consumed. Removing the instance after use prevents unnecessary charges for idle resources, reinforcing the importance of cost-efficient resource management within cloud services. This practice ensures savings and optimal utilization of services .

The standard approach for practicing SQL queries on an AWS RDS MySQL database involves creating a table and performing various SQL operations such as inserting, retrieving, and deleting data. Specifically, one can create a table 'emp' and manipulate data within it using SQL queries. This approach is important because it provides a hands-on experience in managing data, ensuring that users can effectively interact with and understand the relational database systems within a cloud environment .

Integrating AWS RDS with applications like Springboot enhances functionality by allowing seamless database connectivity and enabling applications to handle data-related operations more efficiently. This integration supports the retrieval, update, and management of datasets within a managed database environment, which can scale with application demands, ensuring robust, responsive, and scalable applications suitable for complex use cases .

AWS RDS addresses the challenges of on-premise database systems by providing a fully managed service where the cloud provider manages the database servers, thus eliminating the need for users to handle server licenses, installations, and administrative tasks. RDS ensures high availability, scalability, and security, and operates on a 'pay as you go' model, eliminating the need for manual backups and reducing the burden on DBAs .

The steps involved in creating and testing a MySQL DB Server using AWS RDS include: creating the MySQL DB Server, enabling port 3306 in the security group inbound rules, and testing the MySQL DB connection using MySQL Workbench. This includes checking database connectivity using endpoint, username, and password details provided by AWS RDS. Once connectivity is confirmed, users can execute SQL queries to verify data manipulation tasks .

Using SQL on a database allows users to perform a variety of tasks categorized under CRUD operations. These tasks include creating new tables or records (Create), retrieving or querying specific data (Retrieve), updating existing data records (Update), and deleting data records (Delete). These operations facilitate efficient management and manipulation of data within the relational database structure .

The primary challenges associated with setting up an on-premise database system include the need to purchase a database server license, install the database server software, ensure security, manage network configuration, and achieve high availability and scalability. Additionally, there are challenges concerning backup solutions and administration, typically requiring a Database Administrator (DBA).

Relational databases store data using tables, which organize information into rows and columns. Each table represents a collection of similar data types. SQL, or Structured Query Language, is utilized to communicate with relational databases and perform CRUD operations (Create, Retrieve, Update, Delete). Through SQL, users can efficiently manage and manipulate large datasets within these databases .

Enabling the port number 3306 in the security group inbound rules is essential because it allows MySQL clients to connect to the MySQL database server. Port 3306 is the default port for MySQL, and allowing inbound traffic through this port enables successful connectivity from client applications, such as MySQL Workbench, to the database server hosted on AWS RDS .

Using the 'Standard Create' and 'Free Tier' options when setting up a MySQL DB instance on AWS RDS is significant for beginners as it simplifies the creation process while minimizing costs. The 'Standard Create' method provides a guided setup approach, ensuring essential configurations are correctly applied, while the 'Free Tier' offers cost-free access to AWS's basic RDS services, allowing beginners to explore and learn without financial risk. This approach encourages experimentation and learning critical for mastering database management systems in a cloud environment .

You might also like