Home Amazon Web Services EC2 (Elastic Compute Cloud)

EC2 (Elastic Compute Cloud)

by anupmaurya
8 minutes read
EC2 (Elastic Compute Cloud)

In this article, you’ll learn about EC2 (Elastic Compute Cloud)

EC2 stands for Amazon Elastic Compute Cloud. EC2 enables you to create virtual computers in the Cloud and you don’t need to manage any hardware. It’s a cost-efficient service compared to an on-premises computational network.

  • Amazon EC2 is a web service that provides resizable compute capacity in the cloud.
  • AWS has plenty of predefined EC2 images (i.e., Linux, Windows), and you can also use your own images. These images are called AMI (Amazon Machine Image *pretty unspectacular, isn’t it*)?

 Currently, AWS has the following most preferred set of operating systems available on the EC2 console.

EC2 (Elastic Compute Cloud)
EC2 Images Options
  • You can select how powerful the underlying hardware needs to be, by choosing storage type, CPU and if required GPU power.
  • You can scale the compute capacity up and down as per the computing requirement changes.
  • Amazon EC2 changes the economics of computing by allowing you to pay only for the resources buy a physical server that you actually use. Not like in previous days, if you buy a physical server then you have to pay for the whole whether you are using it or not.

AWS offers Different options for purchasing EC2

AWS offers Different options for purchasing EC2
AWS offers Different options for purchasing EC2
  1. On Demand Instances: You have to pay a fixed price per hour as long as the instance is running.

Pros:

High Availability, pay for use only, great for reliable short-term computing tasks.

Cons:

Can be expensive over a long period of time.

Use Cases:

Prototype Development, Extra capacity in case of unexpected computational demand.

  1. Reserved Instances: You have to sign a fixed term agreement to use instance for 1–3 years.

Pros:

Cheaper than On-Demand Instances, High Availability, great for reliable long-term computing tasks.

Cons:

Can be expensive if the instance has a lot of unused idle time.

Use Cases:

Prototype Development, Extra capacity in case of unexpected computational demand.

Types of Reserved Instances:

  • Standard Reserved Instances
  • Convertible Reserved Instances
  • Scheduled Reserved Instances

Standard Reserved Instances

  • It provides a discount of up to 75% off on demand. For example, you are paying all up-fronts for 3 year contract.
  • It is useful when your Application is at the steady-state.

Convertible Reserved Instances

  • It provides a discount of up to 54% off on demand.
  • It provides the feature that has the capability to change the attributes of RI as long as the exchange results in the creation of Reserved Instances of equal or greater value.
  • Like Standard Reserved Instances, it is also useful for the steady state applications.

Scheduled Reserved Instances

  • Scheduled Reserved Instances are available to launch within the specified time window you reserve.
  • It allows you to match your capacity reservation to a predictable recurring schedule that only requires a fraction of a day, a week, or a month.
  1. Spot Instances: eBay-like pricing model, AWS offers unused EC2 resources to the highest payer. Usually, you can save more than 50% compared to the On-Demand or Reserved Instances.

Pros:

Cheapest EC2 option, great for short-term computation which can be interrupted.

Cons:

AWS can terminate the instance at any time, depending on the market price you may have to wait for some time, till your offer matches the market price and the instance can start booting.

Use-Cases: 

Extra computational capacity for unpredictable workloads that can be interrupted (for instance you can have a fleet of Reserved instances running the webservers, and in case of a sudden spike in demand you can request Spot instances to take care of the additional workload).

  1.    Dedicated Hosting: You reserve the entire hardware server/rack for your instance (it’s not a virtual machine any more).

Pros:

Great for isolated computation (high security).

Cons:

Most expensive EC2 service.

Use-Cases:

Enterprise databases with high-security requirements.

  1. Spot Fleets Instances: Spot-fleets can be used to combine all the services above to a cost-efficient strategy. You can have a bunch of Reserved instances to take care of the core workload, and a combination of On-Demand and Spot instances to handle the workload spikes.

Spot fleets are great to use in Auto Scaling Groups.

What Is Security Group In Amazon Ec2?

Security groups act as a firewall for associated instances, controlling both inbound and outbound traffic at the instance level.

How To Launch An Amazon Ec2 Instance?

We can launch Linux/Windows Amazon EC2 instance using AWS Management Console.
Following are the steps to create Amazon EC2 instance:
1. Open the Amazon EC2 console.
2. From the console dashboard, choose Launch Instance.
3. Choose an Amazon Machine Image (AMI).
4. Choose an Instance Type.
5. Click on Review and Launch to let the wizard complete the other configuration setting.
6. On the Review Instance Launch page, under Security Groups select a Security Group.
7. Click on Launch on the Review Instance Launch.
8. Select an Existing ket pair when it prompt for key pair.
9. Click on View Instance to return to the console to see instance is launching.

You may also like

Adblock Detected

Please support us by disabling your AdBlocker extension from your browsers for our website.