EC2 Section Flashcards

1
Q

EC2

A

• EC2 = Elastic Compute Cloud = Infrastructure as a Service

It mainly consists in the capability of :
• Renting virtual machines (EC2)
• Storing data on virtual drives (EBS)
• Distributing load across machines (ELB)
• Scaling the services using an auto-scaling group (ASG)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

EC2 User Data

A
  • It is possible to bootstrap our instances using an EC2 User data script.
  • That script is only run once at the instance first start
  • EC2 user data is used to automate boot tasks
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

EC2 Naming Convention

A

m5.2xlarge

  • m: instance class
  • 5: generation (AWS improves them over time)
  • 2xlarge: size within the instance class
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

EC2 Instance Types – General Purpose

A

• for web servers or code repositories

Balance between:
• Compute
• Memory
• Networking

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

EC2 Instance Types – Compute Optimized

A
compute-intensive tasks that require high performance processors:
• Batch processing workloads
• Media transcoding
• High performance web servers
• High performance computing (HPC)
• Scientific modeling & machine learning
• Dedicated gaming servers
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

EC2 Instance Types – Memory Optimized

A

• Fast performance for workloads that process large data sets in memory

Use cases:
• High performance, relational/non-relational databases
• Distributed web scale cache stores
• In-memory databases optimized for BI (business intelligence)
• Applications performing real-time processing of big unstructured data

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

EC2 Instance Types – Storage Optimized

A

• Great for storage-intensive tasks that require high, sequential read and write
access to large data sets on local storage

Use cases:
• High frequency online transaction processing (OLTP) systems
• Relational & NoSQL databases
• Cache for in-memory databases (for example, Redis)
• Data warehousing applications
• Distributed file systems

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Security Groups

A
  • They control how traffic is allowed into or out of our EC2 Instances (firewall)
  • Locked to a region/VPC but can be attached to multiple instances
  • only contain allow rules
  • rules can reference by IP or by security group
  • All inbound traffic is blocked by default
  • All outbound traffic is authorised by default

They regulate:
• Access to Ports
• Authorised IP ranges – IPv4 and IPv6
• Control of inbound network (from other to the instance)
• Control of outbound network (from the instance to other)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Ports to know

A
  • 22 = SSH (Secure Shell) - log into a Linux instance
  • 21 = FTP (File Transfer Protocol) – upload files into a file share
  • 22 = SFTP (Secure File Transfer Protocol) – upload files using SSH
  • 80 = HTTP – access unsecured websites
  • 443 = HTTPS – access secured websites
  • 3389 = RDP (Remote Desktop Protocol) – log into a Windows instance
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

SSH

A

• allows you to control a remote machine, all using the command line

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

EC2 Instance Connect

A
  • Connect to your EC2 instance within your browser
  • No need to use your key file that was downloaded
  • The “magic” is that a temporary key is uploaded onto EC2 by AWS
  • Works only out-of-the-box with Amazon Linux 2
  • Need to make sure the port 22 is still opened
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

EC2 On Demand

A

Pay for what you use:
• Linux or Windows - billing per second, after the first minute
• All other operating systems - billing per hour

  • Has the highest cost but no upfront payment
  • No long-term commitment
  • Recommended for short-term and un-interrupted workloads
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

EC2 Reserved Instances

A
  • Up to 72% discount compared to On-demand
  • Reservation period: 1 year = + discount | 3 years = +++ discount
  • Reserve a specific instance type

Convertible Reserved Instance
• can change the EC2 instance type
• Up to 45% discount

Scheduled Reserved Instances
• launch within time window you reserve
• When you require a fraction of day / week / month
• Commitment for 1 year only

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

EC2 Spot Instances

A
  • Can get a discount of up to 90% compared to On-demand
  • Instances that you can “lose” at any point of time if your max price is less than the current spot price
  • The MOST cost-efficient instances in AWS
  • Useful for workloads that are resilient to failure
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

EC2 Dedicated Hosts

A
  • physical server with EC2 instance capacity fully dedicated to your use. can help you address compliance requirements and reduce costs by allowing you to use your existing server-bound software licenses.
  • Allocated for your account for a 3-year period reservation
How well did you know this?
1
Not at all
2
3
4
5
Perfectly