Amazon Elastic Compute Cloud (EC2) Linux

Amazon Elastic Compute Cloud (EC2) for Linux

In here we are talking about Amazon Elastic Compute cloud means it is not most usable name because everyone know by EC2 and it is really very popular service of AWS. In this service which is in compute part of AWS, is a web-service which provides secure, resizable compute capacity on cloud. Specially it is design to make web-scale cloud computing more easy for developer. For more details foe AWS EC2 just click on image which is given below,

This lab Will cover following steps which is as bellow,

  1. Login in AWS using proper credential.
  2. Create Amazon Linux Instance from Amazon Machine Image (AMI).
  3. Found newly created instance from the list.
  4. Login to new created instance.

 

Step 1: Login using appropriate credential for AWS

First of all you have to login in AWS to access the services,

 

Step 2: Create Amazon EC2 Instance

Click on Services and select EC2 which is in Compute section,

 

After select EC2 from compute section just click on Launch Instance,

 

After hit on Launch Instance button you can see a main process of the creating instance in EC2. In here total seven steps with different different configuration what we need for our instance just select it and make it. In the first step just select a machine image from the list,

I am going with Amazon Linux AMI.

 

After selection of image of machine just go to the next step and you can show a list of different different instance with different features select one of them which is good for you, In here you can see that how many CPU are there and also memory and storage type of this Instance. You can make sure about that instance supports IPV6 or not.

I will go with General purpose -t2.small type,

 

In the next step, we are going to configure instance with security group, provide subnets for IPV4 and also for IPV6 if we have and also in here we are able to increase the number of total instance as per our requirement. In bellow picture I will show a configuration for this instance also provide about storage and also final step which is for select security group, for this instance I will go with existing one also provide IAM for the specific group to use this Instance.

 

For Linux instance there are by default security type SSH and click on launch,

 

Step 3: Take a look of new Created Instance in the list

At the end just click on Instances on the left hand side and select a new created instance and take a look, In the status checks, we can see 2/2 checks means this instance is ready to run at this time,

 

Step 4: Login To New Created Instance

To login to the new created Instance we are going to use Public DNS of that Instance and also use PUTTY for the login to that instance,

First copy the public DNS of that Instance,

 

After that Download PUTTY software from the give link just click on here , After download it open PUTTY generator and convert your security file which is in pem format change it in to PPK by following steps as bellow,

Click on load button and select that pem file from the system, after that you can see this popup message on the screen which shows successfully import that file and then just click OK.

 

After that click on Save Private Key and click on YES,

After that give a new name of that file and save on destination where you want,

 

After this open PUTTY and copy Public DNS on the Host name for IP address and use a default port number which is 22,

 

Then click on SSH on the left panel and go to the Authentication section in the SSH, browse that PPK file from the system, after that hit on OPEN button in the bottom of that PUTTY window

At the end you can see a first connection to this remote SSH Server.

END OF THIS LAB

Conclusion
After creating an EC2 instance for Linux we have to download PUTTY for access that Linux instance. After that there is a putty generator click on it and convert your access key file from  pem file to PPK format. After that put that file to PUTTY in SHH and click on Authentication then browse that file and login. This is the only way to assess Linux instance.

One more thing I want to say, if you forgot the key file or delete it, Do not get panic just create new IAM for that Instance and then launch that IAM as a instance using same configuration and select a key or generate a key for that Instance. After that you are able to login in the same instance after this process.

Charges

Basically for Amazon EC2, there are no any basic charges for the creating only charges will be apply what ever you use. There are four different types of EC2 instances which is as bellow,

  • On-Demand
  • Reserved Instances
  • Sport Instances
  • Dedicated Hosts

On-Demand Instance if we take one Instance with 24 hour usage with windows OS with t2.micro type they will charge $14.64 per month. Also include 1 elastic IP and 5 GB data transfer IN and 3 GB data transfer OUT with 2 Elastic Load balancer. For hour £0.02 per hour but to transfer data from EC2 to outside internet they will charge $0.140 per GB fro next 10 GB per month.

Reserved Instance in here they will provide for a contract like for one or more then a year. With the All Upfront option, you pay for the entire Reserved Instance term with one upfront payment. This option provides you with the largest discount compared to On-Demand instance pricing. With the Partial Upfront option, you make a low upfront payment and are then charged a discounted hourly rate for the instance for the duration of the Reserved Instance term. The No Upfront option does not require any upfront payment and provides a discounted hourly rate for the duration of the term. For example about t2.micro in All Upfront is $140 no monthly payment and you will save 20% as compare to on-demand. In Partial Upfront the charges is $74 and each month $5.84 that means every hour you will charge $0.017 and you will save 18% as compare to On-Demand. IN No UpFront nothing to give just pay for every month and you will save 5%.

Stop Instance are set by Amazon EC2 and fluctuate periodically depending on the supply of and demand for Spot instance capacity also available at a discount of up to 90% compared to On-Demand pricing. For t2.micro they will charge you $0.0046 per hour for Linux and for Windows $0.0061 per hour.

Dedicated Hosts fluctuates by occasion family, area, and installment alternative. Despite the amount or the measure of occurrences that you dispatch on a specific Dedicated Host you pay hourly for every dynamic Dedicated Host, and you are not charged for example utilization.

To minimize the cost make sure which kind of environment you want how much time you want to use and how many instance you need for this. After that if you want to store more data then do not go with high storage which is inbuilt just create a external Storage using EBS and then assign to the instance this will beneficial.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s