Create EC2 instance from AWS Console

Rahul K
FAUN — Developer Community 🐾
5 min readFeb 23, 2020

--

What is EC2 Instance?

Secure and resizable compute capacity in the cloud.

Amazon Elastic Compute Cloud ( Amazon EC2) is a web service that provides secure, resizable compute capacity in the cloud. It is designed to make web-scale cloud computing easier for developers.

In this article let us see how to create On-demand EC2 instance from Console.

Login to AWS Console:

Login to AWS management console

Choose Services and select EC2.

You should see the EC2 Dashboard, It describes the counts of resources such as running instances, security groups, key pairs, Elastic IPs, snapshots, Volumes, etc.

Important: “Be sure to choose the right AWS region you want to launch the Instance”.

Choose Instances and you should see the following screen

Now click Launch Instance

Step 1: You should choose the AMI from which you want to launch an instance, AMI (Amazon Machine Images) is nothing but an Operating system such as Centos, Ubuntu, SUSE, Windows etc.

For example, I want to launch an Instance with OS: Ubuntu 18.04, Select the AMI

Step 2: Here Based on your requirements, you can select the instance type such that How much RAM and CPU you need.

I want an instance with 1 vCPU and 2 GB RAM, so I have chosen t2.small

Click Next: Configure Instance Details

Step 3: Now we need to configure few details such as In which network (VPC), subnet, Availability Zone, IAM role before launching a server.

For now, we will use the default values

Choose Next: Add Storage

Step 4: configure the amount of storage (Hard Disk space) you want.

Choose Next: Add Tags

Step 5: Tag is nothing but we are giving a name to the server we are launching for identification.

Select Add Tag and type the details as shown below, You can set as you need.

Choose Next: Configure Security Group

Step 6: Security group is like a firewall that provides security to your instance by controlling protocol, port-level access.

Here we will allow port 22, So that we can be able to SSH into the server after we launch.

Make sure to give a name to a security group for easy management.

Note: you can modify Security at any time.

Choose Review and Launch

Step 7: Here is the review of all the configurations for the EC2 instance, Once you validate, Choose Launch

Since this is the first time you are launching an instance, You should create a key pair using which you can SSH into the server.

Choose “Create a new key pair”, give a name to it, and Download Key Pair

Choose Launch Instance.

Clicking the instance id will take you to the EC2 Instance page.

Now that If you see the Instance state is running, Your instance is ready and you should be able to login to the server.

Connecting to EC2 Instance using Key Pair:

Go to the folder where you have downloaded your key pair.

Set the permission to user only:

chmod 400 testinstance1.pem

Use the below command to SSH into the server:

#ssh -i testinstance1.pem ubuntu@18.140.198.227

Note:

If you have launched Ubuntu OS, your Username is ubuntu

If you have launched Amazon Linux, the username is ec2-user

You have successfully logged into the server.

Conclusion:

We saw in detail how to create an EC2 Instance using the AWS Management Console. You can stop the instance when not required to reduce costs.

Hope you liked it, Please do Check out my other posts.

Originally published at https://fitdevops.in.

👋 Join FAUN today and receive similar stories each week in your inbox! Get your weekly dose of the must-read tech stories, news, and tutorials.

Follow us on Twitter 🐦 and Facebook 👥 and Instagram 📷 and join our Facebook and Linkedin Groups 💬

If this post was helpful, please click the clap 👏 button below a few times to show your support for the author! ⬇

--

--

Pro-Active Devops Engineer with 5+ years of experience in Linux , Amazon Web Services, Azure , GCP , Devops tools. Blogs here : https://fitdevops.in