EC2 Flashcards

1
Q

Pricing of On Demand EC2 Server

A

Fixed rate by hour (or second) with no commitment

Good for apps with short term spiky or unpredictable workflows

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

Pricing of Reserved EC2 Server

A

Provide with capacity reservation getting a discount on hourly charge for instance.

Must set for 1-3 year terms

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

Reserved Instance EC2 types and % discount

A

Standard RI
- up to 72% discount

Convertible RI
- up to 54% off
- feature capability to change attributes of RIs as long as exchange is equal or greater value

Scheduled RI
- Available to launch within time window you reserve.
- Good for predictable schedule

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

What is a Spot Instance?

A

EC2 instance where you big price you want on instance capacity.

Great for apps with flexible start and end times

Up to 90% discount

Fluctuates based on supply and demand

Good for users w/ urgent need for large amounts of additional computing capacity

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

What are EC2 Dedicated Hosts?

A

Most expensive EC2 Server (physical server).

But, it can help reduce cost by allowing you to use existing server bound software.

Can be purchased on demand (hourly) but is really expensive

Also can be purchased as a reservation for up to 70% off on demand price.

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

What happens if your spot instance is terminated by EC2 half-way through the hour?

A

You will not be charged for a partial hour of usage

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

What happens if you terminate a spot instance yourself (cost-wise)?

A

You will be charged for any hour in which the instance ran

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

TRUE or FALSE: You can encrypt the root device volume?

A

TRUE

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

TRUE or FALSE: Termination protection is enabled by default on EC2?

A

FALSE, must turn it on yourself

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

What is default action of root EBS volume when EC2 instance is terminated?

A

Root volume is deleted, but other EBS volumes are NOT deleted

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

What are the underlying hypervisors for EC2?

A

Zen and Nitro

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

How can you access the private and public IP address of an EC2 Instance?

A

Use CURL or GET to access the instance metadata

URI: http://169.254.254/latest/meta-data/Instance

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

How can you add metadata to an EC2 instance?

A

Use tags

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

What is an EC2 Spot Fleet?

A

A group of Spot and optional On-Demand Instances. AWS will launch a number based on the specified target capacity. It will be fulfilled if the max price you picked exceeds current Spot Price.

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

What is a EC2 Spot Block?

A

Stop your EC2 instance form being terminated even if Spot price goes over you max Spot price.

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

What time interval can a Spot Block be set?

A

1-6 hours

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

What are EC2 Spot Instances used for?

A

Big data and analytics
Containerized Workloads
CI/CD testing
Web services
Image and media rendering
High Performance Computing (HPC)

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

What are EC2 Spot Instances NOT good for?

A

Persistent workloads
Critical jobs
Databases

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

What items do you specify in an EC2 Spot request

A

Max price
Desired # instances
Launch specs
Request type: one-time | persistent

One-time (request once)
As soon as spot price goes over max price the spot instance is ended

Persistent
When spot goes over max then keeps going though cycle

Valid from, Valid until

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

EC2 Spot Fleet Options

A

Capacity Optimized

Diversified

LowestPrices (default)

InstancePoolsToUseCount (spot instances distributed across a number of Spot Instance pools you specify. Param is valid only when used in-combination with lowestPrice

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

What is EC2 Hibernate?

A

Hibernate EC2 instance.

Saves contents of RAM to EBS root volume allows for faster reboot

Resume and keeps save instance ID

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

What is EC2 Hibernate useful for?

A

long-running processes
Servcies that take a long time to initialize

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

Size of RAM needed to perform EC2 hibernate

A

less than 150GB

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

Max amount of time an EC2 instance can be hibernated for?

A

60 days max

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

EC2 Instance types that can be hibernated

A

On-Demand
Reserved

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

EC2 instance families that can be hibernated

A

C, M, R 3-5

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

Perquisite of enabling hibernation on EC2 instance?

A

Root Volume must be ENCRYPTED

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

What is an EC2 Security Group?

A

You can attach a security group to an EC2 instance that acts like a virtual firewall. It can be used to control traffic (for 1 or more instance).

These can be edited at any time and new rules will be applied immediately.

29
Q

TRUE or FALSE: Security Groups are Stateful

A

True

If create inbound rule, outbound rule is created automatically. (anything allowed in is also allowed out)

30
Q

TRUE or FALSE: Security Groups can be used to Blacklist IP addresses

A

FALSE

only NACLs can blacklist

31
Q

Do EC2 Security Groups BLOCK, ALLOW, or BOTH

A

ALLOW

Everything by default is blocked

32
Q

What is an Elastic IP address?

A

Static IPv4 address for dynamic cloud computing. You can remap the address to another instance in your account if there is an instance failure.

You will need this if you do not auto-assign a public IP address.

33
Q

Is there a Limit to # of Elastic IP addresses you can have?

A

Yes, there is a limit of 5 per region.

34
Q

How can you distribute traffic among instances?

A

Use and Elastic Load Balancer

35
Q

Use and Elastic Load Balancer

A

Memory utilization
disk swap utilization
disk space utilization
page file utilization

Note CloudWatch Agent must be installed on EC2 server

36
Q

How to retrieve user data from running instance?

A

http://169.254.169.254/latest/user-data

37
Q

What happens if you stop an instance, modify its user data, and start the instance?

A

Modified user data is lost.

38
Q

EC2 User Data Size limit

A

16KB

39
Q

What is the EC2 User Data used for?

A

After instance is started, runs auto configuration tasks and scripts

40
Q

What is an EC2 placement group?

A

It determines how instances are placed on underlying hardware

41
Q

List strategies for EC2 placement groups

A

Cluster
- puts instances into a low-latency group in a single AZ

Spread
- spreads instances across underlying hardware

Partition
- each partition has own set of racks. No 2 partitions have same rack. Makes it easier to isolate impact failures.

42
Q

How to detach a EBS root volume from an EC2 instance?

A

Stop instance and then detach the volume

43
Q

When to use Cluster EC2 Placement Group

A

Want all instances in 1 AZ
Need low-latency high throughput or both
Only CERTAIN instances can be launched into Cluster placement Group

44
Q

When to use Spread EC2 Placement Group

A

Want EC2 to all be put on separate hardware

Ex. want DB instance and app server on different machines/hardware

Recommended for apps with small # of critical instances that should be kept separate from each other

Can be in multiple AZ zones all in 1 region

INDIVIDUAL critical instances (1 instance on each rack)

45
Q

For EC2 Placement groups is there a max # of instances per AZ?

A

Yes 7 per AZ

46
Q

What EC2 Placement Group(s) should you use if you want to put EC2s in multiple AZs in 1 region

A

Spread or Partitioned

47
Q

When to use Partitioned EC2 Placement Group

A

Can have multiple EC2 instances in a partition

Each partition is on own set of racks

Isolate impact of hardware failures

HDFS, HBase and Cassandra cluster

Can be multiple AZ zones all in 1 region

MULTIPLE EC2 Instances (on each rack)

48
Q

TRUE or FALSE: you can merge EC2 placement groups

A

FALSE

49
Q

TRUE or FALSE: you can move STOPPED instances to a placement group using AWS Console

A

FALSE

Can only move them with AWS CLI or AWS SDK

50
Q

How are Windows EC2 Servers Billed?

A

By the Hour

51
Q

What are 2 recommended strategies for having the best experience in terms of availability for Spots instances?

A

Use Proactive capacity rebalancing

Use capacity optimized allocation

52
Q

Standard network card for EC2 instance

A

ENI (Elastic Network Interface) . Use multiple ENI for each network.

53
Q

High Performance Networking for EC2 with Single Root IO Virtualization and high preformance

A

EN (Enhanced Networking)

54
Q

What EC2 Networking is needed for rates of 10 GBps - 100 GBps

A

EN (Enhanced Networking)

55
Q

Options for EN Networking

A

ENA (Elastic Network Adapter) - always use

Intel VFA

56
Q

Networking for EC2 needed for HPC and Machine Learning

A

EFA (Elastic Fabric Adapter)

57
Q

Which Networking adapters uses OS By-pass

A

EFA (Elastic Fabric Adapter) only supported in LINUX

58
Q

For a Spot Instance: How long do you have to either stop or terminate your instance if it goes above the max Spot price?

A

2 minutes

59
Q

How to extend your private VMware Cloud into public AWS

A

VCenter on AWS Cloud ordered through VMware

60
Q

When to use Outpost Racks

A

You have a datacenter (large deployments)

61
Q

When to use Outpost Servers

A

Small space requirements for local compute and networking

62
Q

How to extend AWS to your datacenter

A

Outposts

63
Q

TRUE or FALSE, the default NACL can be updated

A

TRUE

64
Q

TRUE or FALSE, the default SG can be deleted?

A

FALSE, but you can update it

65
Q

TRUE or FALSE, you can remove the default * astrick rule in a NACL

A

FALSE, it also cannot be updated

66
Q

TRUE or FALSE, launch configurations allow for versioning

A

FALSE, use launch templates if you need versions

67
Q

Default Cool down period of ASG

A

300 seconds
(5 minutes)

68
Q

How to setup setup disaster recovery solution on AWS using VMware servers?

A

Contact your VMware representative to provision dedicated hardware within AWS in which you can deploy vCenter yourself.

69
Q

Your boss is concerned about over-provisioning resources when an Auto Scaling event occurs. Which dynamic scaling policy should be used to prevent this

A

Target tracking scaling