Amazon ElastiCache for Redis | Multi-AZ Flashcards

1
Q

Should I be concerned about latency?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

Availability Zones are engineered to provide low latency network connectivity to other Availability Zones in the same Region. In addition, you may want to consider architecting your application and other AWS resources with redundancy across multiple Availability Zones so your application will be resilient in the event of an Availability Zone failure.

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

What is Multi-AZ for ElastiCache for Redis?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

An ElastiCache for Redis shard consists of a primary and up to five read replicas. Redis asynchronously replicates the data from the primary to the read replicas. During certain types of planned maintenance, or in the unlikely event of ElastiCache node failure or Availability Zone failure, Amazon ElastiCache will automatically detect the failure of a primary, select a read replica, and promote it to become the new primary. ElastiCache also propagates the DNS changes of the promoted read replica, so if your application is writing to the primary node endpoint, no endpoint change will be needed.

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

What are the benefits of using Multi-AZ?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

The main benefits of running your ElastiCache for Redis in Multi-AZ mode are enhanced availability and smaller need for administration. If an ElastiCache for Redis primary node failure occurs, the impact on your ability to read/write to the primary is limited to the time it takes for automatic failover to complete. When Multi-AZ is enabled, ElastiCache node failover is automatic and requires no administration. You no longer need to monitor your Redis nodes and manually initiate a recovery in the event of a primary node disruption.

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

How does Multi-AZ work?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

You can use Multi-AZ if you are using ElastiCache for Redis and have a shard consisting of a primary node and one or more read replicas. If the primary node fails, ElastiCache will automatically detect the failure, select one from the available read replicas, and promote it to become the new primary. When cluster_mode parameter is disabled, ElastiCache will propagate the DNS changes of the promoted replica so that your application can keep writing to the primary endpoint. For cluster_mode enabled, ElastiCache will update the node map of the cluster. ElastiCache will also spin up a new node to replace the promoted read replica in the same Availability Zone of the failed primary. In case the primary failed due to temporary Availability Zone disruption, the new replica will be launched once that Availability Zone has recovered.

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

Can I have replicas in the same Availability Zone as the primary?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

Yes. Note that placing both the primary and the replica(s) in the same Availability Zone will not make your ElastiCache for Redis replication group resilient to an Availability Zone disruption.

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

What events would cause Amazon ElastiCache to fail over to a read replica?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

Amazon ElastiCache will failover to a read replica in the event of any of the following:

Loss of availability in primary’s Availability Zone

Loss of network connectivity to primary

Compute unit failure on primary

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

When should I use Multi-AZ?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

Using Redis replication in conjunction with Multi-AZ provides increased availability and fault tolerance. Such deployments are a natural fit for use in production environments. When running ElastiCache for Redis Cluster with cluster mode enabled, if your shards have one or more read replicas, Multi-AZ will automatically be enabled.

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

How do I create an ElastiCache for Redis replication group with Multi-AZ enabled?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

You can create an ElastiCache for Redis primary and read replicas by clicking “Create” on the ElastiCache Management Console. You can also do so by calling the CreateReplicationGroup API. For existing clusters (Redis 2.8.6, 2.8.19, 2.8.21, 2.8.22, 2.8.23, 2.8.24 and 3.2.4 with cluster_mode=disabled), you can enable Multi-AZ by choosing a cluster and clicking Modify on the ElastiCache Management Console or by using the ModifyReplicationGroup API. Switching a replication group to Multi-AZ is not disruptive to your Redis data and does not interfere your nodes’ ability to serve requests.

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

Which read replica will be promoted in case of primary node failure?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

If there are more than one read replicas, the read replica with the smallest asynchronous replication lag to the primary will be promoted.

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

How much does it cost to use Multi-AZ?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

Multi-AZ is free of charge. You only pay for the ElastiCache nodes that you use.

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

What are the performance implications of Multi-AZ?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

ElastiCache currently uses the Redis engine’s native, asynchronous replication and is subject to its strengths and limitations. In particular, when a read replica connects to a primary for the first time, or if the primary changes, the read replica does a full synchronization of the data from the primary, imposing load on itself and the primary. For additional details regarding Redis replication please see here.

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

What node types support Multi-AZ?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

All available node types in ElastiCache support Multi-AZ with one exception. When using Redis 2.8.x or Redis 3.x with cluster_mode=disabled, T2 family doesn’t support Multi-AZ.

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

Will I be alerted when automatic failover occurs?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

Yes, Amazon ElastiCache will create an event to inform you that automatic failover occurred. You can use the DescribeEvents API to return information about events related to your ElastiCache node, or click the Events section of the ElastiCache Management Console.

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

After failover, my primary is now located in a different Availability Zone than my other AWS resources (for example, EC2 instances). Should I be concerned about latency?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

Availability Zones are engineered to provide low latency network connectivity to other Availability Zones in the same region. You may consider architecting your application and other AWS resources with redundancy across multiple Availability Zones so your application will be resilient in the event of an Availability Zone disruption.

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

Where can I get more information about Multi-AZ?

Multi-AZ

Amazon ElastiCache for Redis | Database

A

For more information about Multi-AZ, see ElastiCache documentation.

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