EBS Flashcards

1
Q

root volume vs attached volume

A

data stored on root volume is lost when the instance is terminated

on attached volume - no

Database should be put on attached volume

an instance can have multiple attached EBS volumes

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

EBS

A

Elastic Block Store Volume is a network drive you can attach to your instances while they run and you can persist your data on it

not a physical drive, uses network to communicate with the instance, so there might be a latency

can be detached and attached to another instance quickly as long as they are in the same AZ

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

EBS and AZ

A

the volume is locked to AZ

to move volume across, you need to shapshot it first

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

EBS capacity

A

volume has a provisioned capacity so we need to specify how many GBs and IOPS we want when we create it

you get billed for what you provisioned, not what you are actually using

we can increase capacity as we go along

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

4 types of EBS volumes

A
  1. GP2 (SSD)
  2. IO1 (SSD)
  3. STI (HDD)
  4. SCI (HDD)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

GP2

A

(SSD)

General purpose SSD volume that balances price and performance for a wide variety of workloads

can only be used as boot volume

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

IO1

A

highest-performance SSD volume for

  1. mission-critical applications
  2. that require sustained IOPS performance
  3. or more than 16000 IOPS per volume which is GP2 limit

low-latency or high-throughput workloads

can only be used as boot volume

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

STI

A

low cost HDD volume designed for frequently accessed, throughput-intensive workloads

streaming workloads requiring consistent, fast throughput at a low price

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

SC1

A

lowest cost HDD volume designed for less frequently accessed workloads

throughput oriented storage for large volumes of data that is infrequently accessed

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

EBS volumes are characterized in

A

Size

Throughput

IOPS - I/O Ops per second

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

GP2 use cases

A
  1. virtual desktops
  2. low-latency interactive apps
  3. development and test environments
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

GP2 size

A

1 GB - 16 TiB

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

GP2 volume IOPS

A

small GP2 volume can burst IOPS to 3000
max IOPS on GP2 is 16000

the rule is 3 IOPS per GB. If you change the size of the volume, IOPS changes too, but never goes over 16000

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

IO1 use cases

A

large database workloads

MongoDB, Cassandra, MS SQL, Oracle …

when you have a critical database

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

IO1 size

A

4 GB - 16 TiB

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

IO1 volume IOPS

A

min 100 - max 64000 (for Nitro instances), for others 32000

IOPS is provisioned and is called PIOPS. When we change the instance size - the IOPS doesn’t change automatically with it. You need to change it.

max 50 IOPS for 1 GB

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

ST1 usage

A

Big data, Data warehouses, Log processing, Apache Kafka

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

ST1 size

A

500 GiB - 16 TiB

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

ST1 IOPS

A

max 500

max throughput 500 MiB/s - can burst

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

SC1 size

A

500 GiB - 16 TiB

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

SC1 IOPS

A

250 max

max throughput 250 MiB/s - can burst

so it’s less good and cheaper ST1

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

disk I/O (i.e. from EBS volumes)

A

is bandwidth dependent.

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

throughput

A

throughput measures the rate at which messages arrive at their destination successfully. Average data throughput tells the user how many packets are arriving at their destination.

measured in bits per second (bps)

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

network latency

A

the speed of traffic on your network.

expressed in milliseconds (ms).

The most common measure of latency is called ‘round trip time’ (RTT). As the name suggests, this is the time it takes for a packet to get from one point on the network to another.

Latency from a general point of view is a time delay between the cause and the effect of some physical change in the system being observed, but, known within gaming circles as “lag”, latency is a time interval between the input to a simulation and the visual or auditory response, often occurring because of network delay in online games.

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

network jitter

A

a variance in latency, or the time delay between when a signal is transmitted and when it is received. This variance is measured in milliseconds (ms) and is described as the disruption in the normal sequence of sending data packets.

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

bandwidth

A

Bandwidth can be measured in bits per second (bps) megabits per second (Mbps) and gigabits per second (Gbps).

Having a high bandwidth doesn’t guarantee high network performance. It is theoretical packet delivery, whereas throughput is practical

If throughput in the network is being affected by network latency, packet loss, and jitter then your service will see delays even if you have a substantial amount of bandwidth available.

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

EBS snapshots

A

are incremental - only backup changed blocks

they use I/O so don’t run them while the app is handling a lot of traffic

you don’t have to detach a volume when doing a snapshot but it is recommended

max 100000 snapshots per account

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

Snapshots are stored in

A

S3 but you won’t see them directly, but you will get billed for S3 space

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

Snapshots and AZ

A

you can copy snapshots across AZ or regions

30
Q

Snapshots and AMI

A

you can create AMI from snapshots

31
Q

EBS volumes restored by snapshots

A

need to be pre-warmed - use fio or dd command to pre-read the entire volume

32
Q

Snapshots can be automated by

A

using Amazon Data Lifecycle Manager

33
Q

to migrate EBS volume to a different AZ or region

A
  1. snapshot the volume
  2. optionally copy the volume to a different region
  3. create a volume from the snapshot in the AZ of your choice
34
Q

When you create an encrypted EBS volume

A
  1. data at rest is encrypted inside the volume
  2. all the data in flight moving between the instance and the volume is encrypted
  3. all the snapshots are encrypted
  4. all volumes created from snapshot are encrypted
  5. when you copy an unencrypted snapshot, you can enable encryption

AES-256

35
Q

Encryption and latency

A

Encryption has a minimal impact on latency

36
Q

How to encrypt an unencrypted EBS volume

A
  1. create an EBS snapshot of the volume
  2. encrypt the EBS snapshot (using copy)
  3. create new EBS volume from the snapshot - the volume will also be encrypted
  4. attach the encrypted volume to the original instance
37
Q

Mbps

A

megabit per second

(symbol Mbit/s or Mb/s, often abbreviated “Mbps”) is a unit of data transfer rate equal to:

1,000 kilobits per second
1,000,000 bits per second
125,000 bytes per second
125 kilobytes per second

38
Q

kbps

A

kilobit per second (symbol kbit/s or kb/s, often abbreviated “kbps”) is a unit of data transfer rate equal to:

1,000 bits per second
125 bytes per second

39
Q

Gbps

A

gigabit per second (symbol Gbit/s or Gb/s, often abbreviated “Gbps”) is a unit of data transfer rate equal to:

1,000 megabits per second
1,000,000 kilobits per second
1,000,000,000 bits per second
125,000,000 bytes per second
125 megabytes per second
40
Q

Tbps

A

terabit per second (symbol Tbit/s or Tb/s, sometimes abbreviated “Tbps”) is a unit of data transfer rate equal to:

1,000 gigabits per second
1,000,000 megabits per second
1,000,000,000 kilobits per second
1,000,000,000,000 bits per second
125,000,000,000 bytes per second
125 gigabytes per second
41
Q

Tbps

A

terabit per second (symbol Tbit/s or Tb/s, sometimes abbreviated “Tbps”) is a unit of data transfer rate equal to:

1,000 gigabits per second
1,000,000 megabits per second
1,000,000,000 kilobits per second
1,000,000,000,000 bits per second
125,000,000,000 bytes per second
125 gigabytes per second
42
Q

kBps

A

kilobyte per second (kB/s) (can be abbreviated as kBps) is a unit of data transfer rate equal to:

8,000 bits per second
1,000 bytes per second
8 kilobits per second

43
Q

MBps

A

megabyte per second (MB/s) (can be abbreviated as MBps) is a unit of data transfer rate equal to:

8,000,000 bits per second
1,000,000 bytes per second
1,000 kilobytes per second
8 megabits per second

44
Q

GBps

A

gigabyte per second (GB/s) (can be abbreviated as GBps) is a unit of data transfer rate equal to:

8,000,000,000 bits per second
1,000,000,000 bytes per second
1,000,000 kilobytes per second
1,000 megabytes per second
8 gigabits per second
45
Q

TBps

A

terabyte per second (TB/s) (can be abbreviated as TBps) is a unit of data transfer rate equal to:

8,000,000,000,000 bits per second
1,000,000,000,000 bytes per second
1,000,000,000 kilobytes per second
1,000,000 megabytes per second
1,000 gigabytes per second
8 terabits per second
46
Q

Mibit/s

A

mebibit per second

1 mebibit = 220 bits = 1048576bits = 1024 kibibits[3]
This unit is most useful for measuring RAM and ROM chip capacity.

The mebibit is closely related to the megabit which equals 106 bits = 1,000,000 bits.

1 megabit = 106bits = 1000000bits = 1000 kilobits.

47
Q

MiB/s

A

mebibyte per second

mebibyte is equal to 1048576bytes, i.e., 1024 kibibytes. The unit symbol for the mebibyte is MiB.

1024 MiB = 1 gibibyte (GiB)

48
Q

Instance Store

A

some instances do not come with Root EBS volume

Instead, they come with Instance Store = ephemeral storage

it is physically attached to the machine where your EC2 is

block storage like EBS

some instance types have it attached. Root is still EBS volume but there is also extra storage called ephemeral0

49
Q

Instance Store Pros

A
  1. Better I/O performance (no network involved)
    very high IOPS, hundreds of thousands of IOPS - EBS cannot achieve this (64000 IOPS is max)
  2. good for buffer / cache / scratch data / temporary content
  3. data survives reboots
50
Q

Instance Store Cons

A
  1. on stop or termination instance store is lost
  2. you can’t resize it on the fly or add new stores to EC2 once you’ve provisione an instance store
  3. backups must be operated by the user
  4. risk of data loss if hardware fails so replicate the data across other ISs in other stores
51
Q

Instance Store capacity

A

disks up to 7.5 TiB tebibytes for the moment

can be stripped to reach 30 TiB

but once you set up a disk in local instance store, it cannot change its size

52
Q

TiB

A

tebibyte

1 tebibyte = 240 bytes = 1099511627776bytes = 1024 gibibytes

1024 TiB = 1 pebibyte (PiB)

53
Q

RAID

A

Redundant Array of Independent drives

Raid is just a collection of disks in a pool to become a logical volume.

54
Q

RAID Stripe

A

RAID0

sharing data randomly to multiple disk. This won’t have full data in a single disk. If we use 3 disks half of our data will be in each disks.

55
Q

RAID Mirroring

A

used in RAID 1

Mirroring is making a copy of same data. In RAID 1 it will save the same content to the other disk too.

56
Q

EBS is already replicated storage because

A

it is automatically replicated across multiple servers in an Availability Zone to prevent the loss of data from the failure of any single component.

This replication makes Amazon EBS volumes ten times more reliable than typical commodity disk drives.

57
Q

EBS RAID0 Stripe

A

if you want to increase performance, for ex., IOPS to 100000

EC2 instance will have one logical volume (RAID0 Stripe) backed by two or more EBS volumes. The data will go to either of them.

58
Q

EBS RAID1 Mirror

A

if you want to mirror your EBS volumes

to increase fault tolerance

EC2 instance will have one logical volume (RAID0 Stripe) backed by two or more EBS volumes. The data will go to both of them

59
Q

EBS RAID

A

is possible as long as the OS supports it (Windows, Linux). It is not something you configure in AWS console, rather on the OS level in EC2 instance

RAID5, RAID6 and RAID10 are not recommended

60
Q

EBS RAID0 Stripe disadvantage

A

if one disk fails, the total logical volume is gone, all the data is failed

increased risk to have faults

61
Q

EBS RAID0 Stripe advantages

A

you get more total disk space and IO, increase in performance

62
Q

EBS RAID0 use case

A
  1. an application that needs a lot of IOPS and doesn’t need fault tolerance
  2. a database that has replication already built-in
63
Q

EBS RAID1 Mirroring disadvantage

A

we have to send the data to 2 EBS volumes at the same time, so we have to use 2 times the network throughput

you need an EC2 instance that has more network throughput to handle writing to several EBS volumes at a time

64
Q

EBS RAID1 use case

A

When fault tolerance is more important than I/O performance; for example, as in a critical application.

65
Q

Root EBS volumes of instances

A

get terminated by default if the EC2 instance gets terminated

you can disable it

66
Q

You have provisioned an 8TB (8000 GB) gp2 EBS volume and you are running out of IOPS. What is NOT a way to increase performance?

A

increase EBS volume size because EBS IOPS peaks at 16,000 IOPS. or equivalent 5334 GB.

You can

  1. mount EBS volumes in RAID0
  2. change to an IO1
67
Q

You would like to leverage EBS volumes in parallel to linearly increase performance, while accepting greater failure risks. Which RAID mode helps you in achieving that?

68
Q

Although EBS is already a replicated solution, your company SysOps advised you to use a RAID mode that will mirror data and will allow your instance to not be affected if an EBS volume entirely fails. Which RAID mode did he recommend to you?

69
Q

You would like to have the same data being accessible as an NFS drive cross AZ on all your EC2 instances. What do you recommend?

A

mount an EFS

70
Q

You would like to have a high-performance cache for your application that mustn’t be shared. You don’t mind losing the cache upon termination of your instance. Which storage mechanism do you recommend as a Solution Architect?

A

Instance Store

provides the best disk performance

71
Q

You are running a high-performance database that requires an IOPS of 210,000 for its underlying filesystem. What do you recommend?

A

It is possible to run a database on EC2. It is also possible to use instance store, but there are some considerations to have. The data will be lost if the instance is stopped, but it can be restarted without problems. One can also set up a replication mechanism on another EC2 instance with instance store to have a standby copy. One can also have back-up mechanisms. It’s all up to how you want to set up your architecture to validate your requirements. In this case, it’s around IOPS, and we build an architecture of replication and back up around it

you can’t use

  • EBS GP2 drive because its max is 16000 IOPS
  • EBS IO1 - max is 64000