Step-by-Step Guide to Create an EC2 Instance
Step-by-Step Guide to Create an EC2 Instance
Log in to AWS Console
- Go to https://aws.amazon.com/ and sign in to your AWS account
Navigate to the search box at the top type EC2
- Click on EC2

- Launch an Instance
- Click "Launch Instance" button

Choose an Amazon Machine Image (AMI)
Name your Instance
Select an OS (e.g., Amazon Linux, Ubuntu, Windows Server), for this guide i’ll select ubuntu server.
- Ubuntu Server 22.04 LTS

Choose an Instance Type
For testing/free tier: t2.micro or t3.micro
For production: Consider t3.medium or larger based on needs

Create a Key Pair
- Give your key pair a name to create new key pair if you don't have one

Download the .pem file (keep this secure!)

Configure Security Group
Create new security group
Add rules to allow traffic:
SSH (port 22) for Linux
RDP (port 3389) for Windows
HTTP (port 80) if it's a web server
For this guide i’ll allow only SSH port 22 for Ubuntu Linux and i’ll keep the default Configure storage as default and click launch instance button.

View Your Instance
Instance is successfully launched click the instance id mark red to view instance.

view your running instance

Click on instance id i-08*********1c5 to view more details of your instance such as private and public IP address. and click connect button at the top to connect to your instance.

Connect to instance
For this guide we will connect to our instance using EC2 instance Connect, Select connect type and click on connect.

View your instance terminal
You have successfully launch and instance.

Conclusion
Creating an Amazon EC2 instance is a straightforward process when you this step-by-step guide. By selecting the right AMI, instance type, and security settings, you can quickly deploy a virtual server in the AWS cloud. Remember to securely store your key pair file, as it’s essential for accessing your instance.
Once your EC2 instance is running, you can install software, host applications, or use it for development and testing. AWS provides scalable and flexible computing power, making EC2 a powerful solution for various workloads..