Amazon EC2

EC2 types, NETWORKING AND Storage

By Abhinay Durishetty
6 mins read
EC2 instance types
Now that we took our first steps into customizing EC2 instances, covering networking, and security groups. Now, let's expand your AWS knowledge by exploring EC2 instance types.

EC2 instance types are like different flavors of virtual servers, each optimized for specific tasks. Think of them as tools in your AWS toolbox, and choosing the right one can significantly impact your application's performance and cost.

The instance type determines the amount of CPU, memory, network speed, and potentially additional resources (like GPU or FPGA) your instance will have.

Instance types in AWS are grouped into families based on their targeted use-case.
General Purpose
These types, such as the T3 or M5 instances, are balanced in terms of CPU and memory and are suitable for a wide variety of workloads.
Compute Optimized
Examples are C5 or C5n instances. They are ideal for compute-heavy applications like batch processing
Memory Optimized

R5 or X1 instances fall under this category and are suitable for memory-intensive applications like database
Accelerated Compute

These instances, such as P3 or G4, offer GPU capabilities and are designed for graphics-intensive applications or machine learning.
Storage Optimized
I3 or D2 instances are optimized for high I/O operations, making them suitable for workloads like NoSQL databases.
EC2 storage options
Represents the number of read and write operations a storage device can perform in a second, which is an indicator of the speed of individual operations.

You have the flexibility to adjust the IOPS (Input/Output Operations Per Second) of your storage volume (that will be attached to your EC2) while creating the EC2 instance.

Throughput measures the amount of data that can be transferred to and from the storage device in a given time frame. It's typically measured in megabytes per second (MB/s) or gigabytes per second (GB/s) and is vital for activities like data migration or streaming.

To get a holistic understanding of storage performance, both IOPS and throughput should be considered. Make changes to IOPS and Throughput tailored to your instance needs.

A best practice is to enable encryption for your volume. You can either choose the default AWS KMS (Key Management Service) key or create a custom KMS key for encryption.
EC2 Best Practices

Termination and Stop Protection:
Acts as a safeguard against accidental termination and unintentional stops . Always consider enabling these options, especially for critical instances.