This article is to help you, How you can set up your EC2 instance under 5 minutes if you follow all the given steps correctly.
First, Log-In to your AWS account. In this tutorial, we are going to use free-tier services.
On the console page, search for "EC2" and click on it.
Click on launch Instance.
Enter Name for your EC2 instance => I have given "My EC2" Here, we are selecting Ubuntu OS. From Amazon Machine Image, Be sure to select "Free Tier Eligible" so that it will not cost you anything.
Next select instance type t2.micro "Free Tier Eligible".
Now we are creating key-pair which we will use to connect to AWS instance from our machine.
Click on "Create new key pair" Enter "Key pair name" => My key Name is "My EC2"
Click on "Create Key Pair" => which will download the key (file with extension .pem) on your machine. Keep it safe.
Next Don't change anything. Keep Network Settings as it is.
Keep Configure Storage as it is.
Click on "Launch Instance" which is on the right bottom side.
You will get following message.
Click on View All Instances.
As you can see, our "My EC2" instance is up and running. (ignore the "FM" instance which I had set up before)
Select our instance and click on connect .
Select "SSH Client" and copy command to connect to our instance from our machine.
Now open terminal on your machine.
Go to the location on your terminal, where your downloaded key is located. ( We downloaded our "Key Pair" in previous steps. )
Paste the command which we copied from AWS "SSH Client" page.
And hit enter.
Congratulations ! You have now access to your AWS EC2 instance.
If you want to exit, enter "logout" command
After your usage, make sure to terminate the instance.
Thanks For Reading ๐