Amazon Virtual Private Cloud in AWS (Amazon Web Services) (PART – 3)
In this article, we will see create a database server inside the private subnet ““192.168.2.0/24 – ap-south-1b (subnet-2)”.
Please check the below link for part-2
Create an Database Server
Go to services and click on EC2 under the compute module to open.
We can see EC2 Dashboard
There are two security groups available by default and click on Launch Instance.
Choose an Amazon Machine Image (AMI)
Select the Operating system of the EC2 instance by choosing any of the Amazon Machine Images (AMI). Select the Microsoft Amazon Linux AMI.
Choose an Instance type
Choose the Type of instance depending on your requirements.
Instance types comprise of varying combinations of CPU, memory, storage, and networking capacity.
select the default option of t2. micro – this instance type is covered within the free tier. Then click on Configure Instance Details.
Configure Instance Details
Configure EC2 instance details as per requirements of your environment.
Choose your VPC network.
Choose subnet 2 “192.168.2.0/24 – ap-south-1b (subnet-2)”
Choose required instances to create webserver and auto-assign public IP should be Disable for private subnet then click on Add Storage.
Here, we can see root volume by default and size of 8GB
Add a new volume if required
Click on Add Tags.
Tags assist in easier identification and classification of the various instances in your AWS environment.
Click on click to add a Name tag to provide name for our server.
Provide the name for the Linux virtual machine for easier understanding and click on Configure Security Groups.
Configure Security Group
A security group allows configuring firewall rules to allow traffic as needed. Only one rule has been added to allow remote connection.
SSH – Secure Shell
Create a new security group name as “DB-SG” and give description with same name.
We need choose MYSQL/Aurora port and open to subnet 1 (public subnet) IP range “192.168.1.0/24.
click on Review and Launch.
Review Instance Launch
Review and confirm the configuration of the instance. Click on the Edit button on each configuration item to make changes and click on Launch.
Create a Key Pair and Launch Your Instance
To connect to your virtual machine, you need a key pair. A key pair is used to log into your instance and Choose create a new key pair
Create a new key pair and name it My Linux. Then click on Download Key Pair.
After you have downloaded and saved your key pair, click on Launch Instance to start your Windows Server instance.
Dbserver.pem be downloaded to your computer — make sure to save this key pair in a safe location on your computer.
click on View Instances to view the instance you have just created and see its status.
we can see WebServer which was created earlier.
Here DBServer has only private IP and there is no Public IP because we launched db server in private subnet.
The database server has been created successfully.
Database server MYSQL/Auror – 192.168.1.0/24.
In Next article,we will see create bastian server inside the public subnet.
Thank you for giving your valuable time to read the above information.
Follow us on
Website : www.ktexperts.com
Facebook Page : KTexperts