AWS Builder Center

Getting Started with Amazon EC2: Understanding Virtual Servers in AWS

A practical introduction to Amazon EC2, covering virtual servers, instance types, AMIs, storage, security groups, SSH, and the basics of deploying a backend application on AWS.

Getting Started with Amazon EC2

When I started learning AWS, one of the first services I explored was Amazon EC2 (Elastic Compute Cloud). EC2 allows developers to launch virtual servers in the AWS Cloud and use them to run applications without managing physical hardware.
For a backend developer, a simple way to think about EC2 is:
Local application → EC2 instance → Application running in the cloud
When launching an EC2 instance, we can choose an AMI (Amazon Machine Image), instance type, storage, networking configuration, and security settings based on the application's requirements.
One of the most important concepts I learned was Security Groups. They act as a virtual firewall for an EC2 instance and control which inbound and outbound traffic is allowed. For example, if a backend application is running on a particular port, the appropriate security rule needs to be configured for external access.
EC2 instances can also be accessed remotely using SSH for Linux-based servers. Once connected, we can install our runtime, dependencies, application code, and other tools required to run the application.
EC2 can also work with services such as Amazon EBS for persistent block storage, Elastic Load Balancing for distributing traffic, and CloudWatch for monitoring applications and resources.
Another important thing I learned while experimenting with EC2 is the difference between stopping and terminating an instance. Stopping shuts down the instance so it can generally be started again, while terminating removes the instance. Understanding the lifecycle of resources is important when experimenting in AWS.
Overall, learning EC2 helped me understand what happens behind the scenes when a backend application moves from a local development environment to the cloud. It also gave me a foundation for exploring concepts such as networking, IAM, load balancing, containers, and cloud architecture.
Any opinions in this article are those of the individual author and may not reflect the opinions of AWS.
Enjoyed reading this content? Let the author know!

Your likes, comments, shares, and saves help creators reach more builders.

Loading recommendations

Loading article