Profile Applicability:
- Level 1
Description:
Amazon DynamoDB Accelerator (DAX) is a fully managed, highly available, in-memory cache for DynamoDB that provides fast read performance. By deploying DAX clusters across multiple availability zones (AZs), you ensure high availability and fault tolerance for your application. This SOP ensures that DAX clusters are configured with nodes spread across multiple AZs, which enhances the availability and reliability of the cache by ensuring that it remains operational in the event of an AZ failure.
Rationale:
High Availability: Deploying DAX clusters across multiple AZs ensures that the service remains operational even if one AZ experiences a failure.
Fault Tolerance: Multi-AZ deployments prevent single points of failure, ensuring that your application can continue to function without interruption.
Improved Performance: Data is cached in multiple locations, improving the resilience and performance of the application under heavy traffic.
Impact:
Pros:
Increased Reliability: The service can continue to function if an AZ fails, ensuring the availability of the cache.
Fault Tolerance: Multiple AZs provide resilience to network or infrastructure failures within a single AZ.
Better Performance: Requests can be routed to the nearest AZ, improving application performance.
Cons:
Cost: Deploying DAX clusters in multiple AZs increases costs due to the extra resources required for additional nodes and data replication.
Complexity: Managing a multi-AZ deployment requires careful monitoring to ensure that all nodes are operational and synchronized.
Default Value:
By default, DAX clusters are created with nodes in a single availability zone. To achieve high availability, it must be explicitly configured to deploy nodes across multiple AZs.
Pre-requisite:
AWS IAM Permissions:
dax:DescribeClusters
dax:ListClusters
AWS CLI installed and configured.
DAX Cluster created or in the process of being created.
Test Plan:
Using AWS Console:
Sign in to the AWS Management Console.
Navigate to Amazon DynamoDB under Services and then to DAX.
Select the DAX Cluster you want to check.
In the Cluster details page, under the Cluster nodes section, check the Availability Zone configuration:
If the DAX cluster is configured across multiple availability zones, nodes will be listed in more than one AZ.
If all nodes are in a single availability zone, the cluster is not using multi-AZ deployment.
Using AWS CLI:
To check if DAX cluster nodes are spread across multiple availability zones, run:
aws dax describe-cluster --cluster-name <cluster-name> --query "Cluster.NodeIds"
This will list the node IDs of the DAX cluster.
To check the availability zone of the nodes, run:
aws dax describe-cluster --cluster-name <cluster-name> --query "Cluster.Nodes[*].AvailabilityZone"
If the output lists multiple availability zones (e.g., us-east-1a, us-east-1b), then the DAX cluster is deployed in multiple AZs. If it lists a single AZ, the cluster is not multi-AZ.
Implementation Steps:
Using AWS Console:
Sign in to the AWS Management Console and navigate to DynamoDB.
Go to the DAX section and select the cluster you want to modify.
In the Cluster Details, under Nodes, click on Modify.
In the Node configuration, select the option to deploy nodes in multiple availability zones.
Review the updated configuration and click Save Changes to apply.
Using AWS CLI:
To create a DAX cluster with multi-AZ nodes, run:
aws dax create-cluster \ --cluster-name <cluster-name> \ --node-type <node-type> \ --replication-factor 3 \ --availability-zones <az-1>,<az-2>,<az-3> \ --subnet-group-name <subnet-group-name> \ --iam-role-arn <role-arn>
To modify an existing DAX cluster to use multi-AZ, run:
aws dax update-cluster \ --cluster-name <cluster-name> \ --replication-factor 3 \ --availability-zones <az-1>,<az-2>,<az-3>
Verify that the DAX cluster is now deployed across multiple AZs by running the describe-cluster command:
aws dax describe-cluster --cluster-name <cluster-name> --query "Cluster.Nodes[*].AvailabilityZone"
Backout Plan:
Using AWS Console:
If adding nodes in multiple AZs causes issues, sign in to the AWS Management Console.
Navigate to DynamoDB, select the DAX cluster, and go to Edit.
Remove the additional AZs, leaving the cluster in the original AZ configuration.
Save the changes and verify that the cluster is no longer using multiple AZs.
Using AWS CLI:
To remove nodes from additional AZs, run the following command:
aws dax update-cluster --cluster-identifier <CLUSTER_ID> --region <REGION> --availability-zones "us-east-1a"
Verify the Availability Zones by describing the cluster again:
aws dax describe-clusters --cluster-identifier <CLUSTER_ID> --region <REGION>