RDS, Aurora & Elasticache Flashcards

1
Q

What are the 6 databases that RDS supports?

A
  • Postgres
  • MySQL
  • MariaDB
  • Oracle
  • Microsoft SQL Server
  • Aurora
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

How many read replicas can you have?

A

Up to 5

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

Are all read replicas in the same AZ?

A

You can have them in the same AZ, cross AZ or cross region

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

What does async replication mean?

A

It means the reads are eventually consistent

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

How does an application leverage read replicas?

A

You need to update the connection string

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

What is a typical use case for read replicas?

A

When you need a reporting application to read data but don’t want the production application to be impacted

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

What SQL keyword can be used with read replicas?

A

SELECT only. Not UPDATE, INSERT or DELETE

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

Do you have to pay for cross AZ traffic in read replicas?

A

If you are within the same region, the cross AZ traffic is free

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

What is RDS Multi AZ for?

A

It is for Disaster Recovery

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

In Multi AZ, how does the application switch from the main DB to the backup DB?

A

The application connects using a DNS name, which will automatically point to the backup if the master goes down.

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

Can read replicas be setup as Multi AZ for Disaster Recovery?

A

Yes

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

How do I make my DB go from single AZ to multi AZ?

A

Just click on Modify in the database and enable multi AZ. It causes zero downtime

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

What happens when I click enable multi AZ?

A
  • A snapshot of the DB is taken.
  • A new DB is restored from the snapshot in a new AZ
  • Synchronization is established between the 2 DBs
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Can I encrypt a read replica?

A

Only if the master is encrypted

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

How do you enforce SSL in Postgres?

A

In the RDS console, in Parameter Groups, set:

rds.force_ssl=1

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

How do you enforce SSL in MySQL?

A

Within the DB, run the following:

GRANT USAGE ON . TO ‘mysqluser’@’%’ REQUIRE SSL;

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

What are the 4 steps to encrypt an unencrypted DB?

A
  • Create a snapshot
  • Copy the snapshot and enable encryption
  • Restore the DB using the encrypted snapshot
  • Migrate apps to the new DB and delete the old one
18
Q

What are the 4 things I am responsible for with RDS security?

A
  • Check ports/IP/inbound security group rules
  • In-DB user creation and permissions or manage through IAM
  • Create a DB with or without public access
  • Ensure parameter groups or DB is configured to allow SSL
19
Q

What is AWS responsible for with RDS security?

A
  • No SSH access
  • No manual DB patching
  • No manual OS patching
  • No way to audit the underlying instance
20
Q

What are the 2 DBs supported by Aurora?

A
  • Postgres

- MySQL

21
Q

How does Aurora maintain high availability and read scaling?

A

It has 6 copies of your data across 3 AZs

22
Q

What are the 6 copies used for?

A
  • 4 copies out of 6 needed for writes

- 3 copies of of 6 needed for reads

23
Q

Does Aurora support cross region replication?

24
Q

What is a Writer endpoint in Aurora?

A

It is the DNS name the clients points to to communicate with the master

25
What is the Reader endpoint in Aurora?
It is the DNS name clients communicate with to read from the DB. This supports Load Balancing to all read replcias
26
What is a custom endpoint in Aurora?
It is a new endpoint you can point at specific Read Replicas to do analytic queries for example
27
What happens when you create a custom endpoint in Aurora?
The Reader Endpoint is no longer used and you need to create custom endpoints to point at specific read replicas
28
What is Aurora Multi Master?
It is when Aurora Serverless allows every node to read/write
29
What is Elasticache?
It allows you to get managed Redis or Memcached
30
What are the 4 features of Redis?
- Multi AZ failover - Read Replicas to scale - Data Durability - Backup and restore features
31
What are 5 things to note about Memcached?
- Multi node for data partitioning - No High Availability - Non persistent - No backup and restore - Multi threaded
32
Does Elasticache support IAM authentication?
no
33
What are the 2 security options for Redis?
- Set a pwd/token when creating a cluster | - Supports SSL for in flight encryption
34
What auth method does Memcached support?
SASL based auth
35
What are the 3 patterns for Elasticache?
- Lazy Loading - Write Through - Session State
36
What is Redis Sorted Sets?
It gaurantees uniqueness and element ordering, so its good for game leader boards etc
37
What is the Postgres port?
5432
38
What is the MySql port
3306
39
What is the Oracle RDS port?
1521
40
What is the MSSQL Server port?
1433
41
What is the MairiaDB port?
3306 - same as MySQL
42
What is the Aurora port?
5432 if Postgres | 3306 if MySQL