EC2 architecture and resilience Flashcards
What are EC2 instances?
EC2 instances are virtual machines run on EC2 hosts
What types of hosts are used in EC2?
Shared hosts: every customer is isolated even on the same shared hardware.
Dedicated hosts: pay for the entire hardware, don’t pay for instances.
What level of resilience does EC2 provide?
AZ resilient service. They run within only one AZ system.
Can you access instances in a cross zone way?
You can’t access them cross zone.
What does an EC2 host contain?
- Local hardware such - CPU and memory
- Also have a temporary instance storage (If instance moves hosts, the storage is lost)
- Can use remote storage, Elastic Block Store (EBS)
What is EBS used for in EC2 instances?
- EBS allows you to allocate volumes of persistent storage to instances within the same AZ.
What types of networking exist in EC2?
- 2 types of networking
- Storage networking
- Data networking
When do EC2 instances get ENIs assigned to them?
When the EC2 instances are created and provisioned within a specific subnet.
What is the function of ENIs?
It maps to the physical hardware on the EC2 host.
Can instances have multiple network interfaces?
Yes
Can EC2 instances have multiple interfaces in multiple subnets?
Yes, as long as the subnets are in the same AZ.
An instance runs on a specific host. If you restart the instance…what happens?
The instance stays in the host.
When will an EC2 instance leave the host where it is running?
- The host fails or is taken down by AWS - maintenance
- The instance is stopped and then started, different than restarted.
When an EC2 instance is moved from its host, where is it relocated?
To another host in the same AZ.
What is a migration of an EC2 instances?
It is taking a copy of an instance and moving it to a different AZ.
In which cases is EC2 useful?
Long running compute needs like server style applications
Mention some server style applications where EC2 is useful:
- things waiting for network response
- long running compute
- traditional OS+Application compute
- burst or steady-state load
- monolithic application stacks
- middle ware or specific run time components
- migrating application workloads or disaster recovery
- existing applications running on a server and a backup system to intervene
The instance types will variate depending on:
- Raw CPU, memory, local storage, capacity & type
- Resource ratios
- Storage and data network bandwidth
- System architecture / Vendor
- Additional features and capabilities - GPUs, FPGAs
What are the main instance categories/types in EC2?
- General-purpose
- Compute-optimized
- Memory-optimized
- Accelerated computing
- Storage optimized
When should you use General purpose type instances?
Default steady-state workloads with even resources.
When should you use Compute-optimized type instances?
Media processing, scientific modeling and high-performance computing, gaming, machine learning.
Provides the latest high-performance CPUs with a higher ratio of CPU over the memory for a given price point.
When should you use Memory Optimized type instances?
perfect for processing large in-memory data sets, in-memory caching, database workloads
What does the Accelerated-computing instances offer?
Hardware GPU, FPGAs. Dedicated GPUs, high-scale parallel processing and modeling, custom programmable hardware such as FPGAs
When should you use Storage optimized type instances?
Large amounts of super fast local storage. Massive amounts of IO per second. Scale-out transactional databases, data warehousing, Elastic search, and analytic workloads.
Designed for high sequential transfer rates
How is the instance type naming scheme in EC2? R5dn.8xlarge
- 1st char: Instance family.
- 2nd char: Instance generation. Generally always select the newest generation.
- 3rd char - before period: additional capabilities
- a: amd cpu
- d: NVMe storage
- n: network optimized
- e: extra capacity for ram or storage
- char after period: Instance size. Memory and CPU considerations.
- It is often easier to scale a system with a larger number of smaller instance sizes.