Fundamentals-RDS,Aurora,ElastiCache Flashcards

1
Q

Amazon ____ is a managed DB service that allows you to create databases in the cloud that are managed by AWS.

A

RDS

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

List 7 database engines that are supported by Amazon RDS

A

Postgres, MySQL, MariaDB, Oracle, Microsoft SQL Server, IBM DB2, Aurora

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

Advantage of RDS vs deploying DB on EC2:
Because RDS is a managed service:
- automated provisioning, OS patching
- continous backups and restore to specific timestamp (Point in Time Restore)
- monitoring dashboards
- read replicas for improved read performance
- multi AZ setup for disaster recovery
- maintenance windows for upgrades
- scaling capability (vertical and horizontal)
- storage backed by EBS

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

One disadvantage of Amazon RDS is that you cannot ____ into your instances. Since they are managed services, you don’t have access to the underlying EC2 instance.

A

SSH

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

What RDS feature can help you increase storage on your RDS DB instance automatically when it detects you are running out of free database storage?

A

RDS - Storage Auto Scaling

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

When configuring RDS Storage Auto Scaling, you need to set a ____ that will be the maximum limit for DB storage.

A

Maximum Storage Threshold

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

Amazon RDS Storage Auto Scaling will automatically modify storage if:
- free storage is less than ____% of allocated storage
- low-storage lasts at least ____ minutes
- ____ hours have passed since the last modification

A

10
5
6

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

Amazon RDS Storage Auto Scaling is useful for applications with ____ workloads.

A

unpredictable

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

Which RDS database engines are supported with the Storage Auto Scaling feature?

A

all of them
Postgres, MySQL, MariaDB, Oracle, Microsoft SQL Server, IBM DB2, Aurora

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

You can have up to ____ read replicas when using Amazon RDS.

A

15
This provides read scalability.

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

Read replicas with Amazon RDS can be Within AZ, Cross AZ or Cross Region.

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

Amazon RDS replication is ____, so the reads are eventually consistent.

A

async

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

Amazon RDS read replicas can be ____ to their own DB.

A

promoted

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

In order to use Amazon RDS read replicas, the application must update the ____ to leverage the read replicas.

A

connection string

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

Use case for RDS Read Replicas:

  • You have a production database for the normal load
  • You want to run a reporting application for analytics
  • You create the read replica to run the reporting against and the production database is not impacted.
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Normally, there is a network cost when data goes from one AZ to another.
For RDS read replicas within the same ____, you don’t pay that fee.

A

region

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

RDS Multi AZ is used for disaster recovery by using ____ replication to a standby RDS DB instance.
This standby instance is not used/accessible unless there is a failover to it.

A

sync

No manual intervention in the apps.
Not used for scaling.

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

RDS Multi AZ provides automatic app failover by using one ____ name.

A

DNS

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

RDS Multi AZ ____ can be triggered in the case an AZ loss, network loss, instance or storage failure.

A

failover

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

An alternative RDS Multi AZ disaster recovery setup to using a standby DB instance, is to use your RDS ____ if they are located in separate AZs.

A

read replicas

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

With RDS, to convert from a Single-AZ to Multi-AZ, there is no need to stop the DB. It is a zero downtime operation.
You simply click the “modify” option for the database.

A

Behind the scenes, how does it work:

  • A snapshot is taken of the RDS DB instance
  • A new DB is restored from the snapshot in a new AZ
  • Synchronization is started between the two databases
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

With RDS ____, you have access to the OS and database customization.
Which two database engines are support by this feature?

A

Custom
Oracle and Microsoft SQL Server

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

RDS Custom allows access to the underlying database and OS so you can:
- configure settings
- install patches
- enable native features
- access the underlying EC2 instance using SSH or SSM Session Manager

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

When using RDS Custom, before you customize anything it is recommended that you do what two things?

A

deactivate automation mode
take a DB snapshot

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

Amazon ____ is a proprietary DB from AWS (not open source) that is compatible with Postgres and MySQL.

A

Aurora

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

Amazon Aurora is “AWS Cloud Optimized” and performance is 5x better than MySQL on RDS and 3x better than Postgres on RDS.

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

Amazon Aurora storage automatically grows in increments of __ GB, up to ___ TB.

A

10
128

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

Amazon Aurora can have up to __ read replicas and the replication process is faster than MySQL (sub 10 ms replica lag).

A

15

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

Failover in Amazon Aurora is ____ and is much faster than Multi AZ on RDS.
It is also high availability natively.

A

instantaneous

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

Amazon Aurora costs about 20% ____ than RDS, but is more efficient especially at scale.

A

more

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

Amazon Aurora stores __ copies of your data across __ AZs
- __ copies out of __ needed for ____
- __ copies out of __ needed for ____
- self healing with peer-to-peer replication
- storage is striped across 100s of volumes

A

6,3
4,6, writes
3,6, reads

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

Amazon Aurora supports:
- automated ____ for master in less than 30 seconds.
- up to __ Aurora read replicas.
- ____ replication

A

failover
15
Cross Region

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

Amazon Aurora uses a ____ endpoint that points to the master DB so you always know which DB is the master. This is done via a DNS.
Amazon Aurora uses a ____ endpoint that points to all the read replicas via connection load balancing.
Amazon Aurora’s read replicas can ____ up to the maximum number of replicates allowed, 15.
Amazon Aurora uses a ____ storage volume that can auto expand from 10GB to 128TB.

A

writer
reader
auto scale
shared

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

Features of Amazon Aurora:
- automatic fail-over
- backup and recovery
- isolation and security
- industry compliance
- push-button scaling
- automated patching with zero downtime
- advanced monitoring
- routine maintenance
- backtrack: restore data to any point in time without using backups

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

You can define a subset of Aurora replica instances as a ____ endpoint.
This allows you to run analytical queries on specific replicas.
Generally, the reader endpoint is not used after defining Custom Endpoints as you would create multiple custom endpoints to cover your replicas.

A

custom

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

Aurora Serverless:

  • automated database instantiation and auto-scaling based on actual usage
  • good for infrequent, intermittent or unpredictable workloads
  • no capacity planning needed
  • pay per second, can be more cost-effective
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
37
Q

Global Aurora:

Cross Region read replicas are useful for ____.

A

disaster recovery

38
Q

Global Aurora:

Aurora Global Database:
- 1 primary region (read / write)
- up to 5 secondary (read-only) regions, replication lag is less than 1 second
- up to 16 read replicas per secondary region
- helps for decreasing latency
- promoting another region (for disaster recovery) has an RTO < 1 minute
- typical cross-region replication takes less than 1 second

39
Q

Aurora ____ enables you to add ML-based predictions to your applications via SQL.
You don’t need to have ML experience.

A

Machine Learning

40
Q

Aurora ____ provides simple, optimized, and secure integration between Aurora and AWS ML services.

A

Machine Learning

41
Q

What two AWS services support the Aurora Machine Learning feature?

A

Amazon SageMaker (use with any ML model)
Amazon Comprehend (for sentiment analysis)

42
Q

What are some use cases for Aurora Machine Learning?

A

fraud detection, ad targeting, sentiment analysis, product recommendations

43
Q

What are the two backup options for an RDS database?

A

automated
manual DB snapshot

44
Q

RDS automated backups do a ____ fully backup of the database (during the backup window).
Transaction logs are backed-up by RDS every ____.
To disable the automated backups, you set the days of retention to ____.
Automated backups provide the ability to restore to any point in time (from oldest backup to ____ ago)

A

daily
5 minutes
0
5 minutes

45
Q

RDS ____ are manually triggered backups by the user.
Unlike RDS automated backups that can only be kept up to 35 days, manual backups ____.

A

manual DB snapshots
are kept as long as you want

46
Q

RDS backup trick:

Let’s say you have a RDS database that you plan to have stopped for a long time. You still will be paying for that storage. Instead, take a manual snapshot of the RDS database and then delete it. This way you are only paying for the cheaper snapshot storage. Then just restore the database when you need to use it again.

47
Q

Aurora automated backups can be retained from 1 to 35 days.
Unlike RDS automated backups, they cannot be ____.

Aurora manual DB snapshots are the same as RDS in that:
- ?
- ?

A

disabled

manually triggered
backups are kept as long as you want

48
Q

Restoring an RDS / Aurora backup or a snapshot creates ____.

A

a new database

49
Q

Restoring MySQL RDS database from S3

  • create a backup of your on-premises database
  • store it on Amazon S3 (object storage)
  • restore the backup file onto a new RDS instance running MySQL
50
Q

Restoring MySQL Aurora cluster from S3

  • create backup of your on-premises database using Percona XtraBackup
  • store the backup file on Amazon S3
  • restore the backup file onto a new Aurora cluster running MySQL
51
Q

Aurora database ____ allows you to create a new Aurora DB cluster from an existing one.

52
Q

Aurora Database cloning is faster than a ____.

A

snapshot and restore

53
Q

Aurora database cloning uses a ____ protocol:

  • initially, the new DB cluster uses the same data volume as the original DB cluster (fast and efficient - no copying needed)
  • when updates are made to the new DB cluster data, then additional storage is allocated and data is copied to be separated
A

copy-on-write

54
Q

What Aurora feature is useful to create a “staging” database from a “production” database without impacting the production database?

A

Aurora Database Cloning

55
Q

With ____ encryption, RDS master and replicas encryption using AWS KMS.

56
Q

When using at-rest encryption with RDS and Aurora, the encryption must be defined at ____.

A

launch time

57
Q

With at-rest encryption for RDS and Aurora, if the ____ is not encrypted, then the read replicas cannot be encrypted.

58
Q

To encrypt an un-encrypted RDS / Aurora database, you must perform what steps?

A

take a DB snapshot and restore as encrypted

59
Q

Amazon RDS provides ____ encrpytion by default with TLS.
You can use the AWS TLS root certificates client-side.

60
Q

Using ____, you can use Roles to connect to your database (instead of username/pw).

A

IAM Authentication

61
Q

____ control network access to your RDS / Aurora DB.

A

security groups

62
Q

There is no SSH available on RDS / Aurora except on RDS ____.

63
Q

Audit logs can be enabled on RDS and sent to ____ logs for longer retention.

A

CloudWatch

64
Q

Amazon RDS ____ is a fully managed database proxy for RDS.

65
Q

Amazon ____ allows apps to pool and share DB connections established with the database.

66
Q

Amazon RDS Proxy can improve database efficiency by reducing stress on ____ and minimize ____.

A

database resources (CPU, RAM, etc)
open connections (and timeouts)

67
Q

Features of Amazon RDS Proxy:
- serverless
- auto scaling
- highly available (multi-AZ)

68
Q

Amazon RDS Proxy can reduce RDS / Aurora failover time by up to 66%.

69
Q

Amazon RDS Proxy supports:
- RDS: MySQL, PostgreSQL, MariaDB, MS SQL Server
- Aurora: MySQL, PostgreSQL

70
Q

No code changes are required in most apps to use Amazon RDS Proxy.
Just point the database connection to the proxy.

71
Q

Amazon ____ allows you to enforce IAM authentication for DB, and securely store credentials in AWS Secrets Manager.

72
Q

The RDS Proxy is never ____ accessible.

A

publicly
only accessible from VPC

73
Q

Use RDS Proxy to pool connections from ____ functions to reduce timeouts and open connections.

74
Q

The three main uses for Amazon RDS Proxy:
- minimize and pool connections on RDS instances
- reduce RDS failover time
- enforce IAM authentication for DB

75
Q

Amazon ____ is a way to get managed Redis or Memcached databases.

A

ElastiCache

76
Q

____ are in-memory databases with really high performance, low latency.
They help to reduce the load off databases for read intensive workloads.
Helps make your application stateless.

77
Q

With Amazon ____, AWS takes care of OS maintenance / patching, optimizations, setup, configuration, monitoring, failure, recovery and backups for in-memory databaeses.

A

ElastiCache

78
Q

Using ElastiCache involves heavy ____ changes.

A

application code

79
Q

ElastiCache Solution Architecture - DB Cache

Applications query ElastiCache, if not available, get from RDS and store in ElastiCache.
Cache must have an ____ strategy to make sure only the most current data is used.

A

invalidation

80
Q

ElastiCache Solution Architecture - User Session Store (making application stateless)

  • user logs into any of the application
  • the application writes the session data into ElastiCache
  • the user hits another instance of the application
  • the instance retrieves the data and the user is already logged in
81
Q

Redis vs Memcached

82
Q

ElastiCache supports IAM Authentication for ____ only, for the rest you use username/password.

83
Q

IAM policies on ElastiCache are only used for AWS ____ security.

84
Q

Memcached with ElastiCache supports ____-based authentication.

85
Q

With Redis AUTH:
- you can set a “password/token” when you create a Redis cluster
- provides an extra level of security for your cache (on top of security groups)
- supports SSL in-flight encryption

86
Q

Which ElastiCache loading pattern is described:

All the read data is cached, data can become stale in cache. Only when you don’t find data in cache do you then load ElastiCache.

a) lazy loading
b) write through
c) session store

A

lazy loading

87
Q

Which ElastiCache loading pattern is described:

Adds or update data in the cache when written to a DB (no stale data)

a) lazy loading
b) write through
c) session store

A

write through

88
Q

Which ElastiCache loading pattern is described:

store temporary session data in a cache (using TTL features)

a) lazy loading
b) write through
c) session store

A

session store

89
Q

Redis ____ guarantee both uniqueness and element ordering.
Each time a new element is added, it is ranked in real time, then added in the correct order. Very userful for gaming leaderboards.

A

sorted sets

90
Q

You should be able to differentiate between an Important (HTTPS - port 443) and a database port (PostgreSQL - port 5432) :

Important Ports:
- FTP: 21
- SSH: 22
- SFTP: 22
- HTTP: 80
- HTTPS: 443

RDS Database Ports:
- PostgreSQL: 5432
- MySQL: 3306
- Oracle RDS: 1521
- MSSQL Server: 1433
- MariaDB: 3306
- Aurora: 5432 (if PostgreSQL compatible) or 3306 (if MySQL compatible)