AWS Services:
Amazon ElastiCache supports the Memcached and Redis cache engines. Each engine provides some advantages. ElastiCache allows you to seamlessly set up, run, and scale popular open-source compatible in-memory data stores in the cloud. Build data-intensive apps or boost the performance of your existing databases by retrieving data from high throughput and low latency in-memory data stores.
Description of the finding:
The node size you select for your cluster impacts costs, performance, and fault tolerance. You can attain your needed cluster memory capacity by having a few large nodes or several smaller nodes. Further, as your needs change, you can add nodes to or remove nodes from the cluster and thus pay only for what you need.
Recommendation:
Consider upgrading ElastiCache instance class from cache.r4 to cache.r5
clusters contain one or more nodes with the cluster's data partitioned across the nodes. The number of nodes in the cluster is a key factor in the availability of your cluster running. If your current node type is cache.r4 which is a bit slower in performance than cache.r5, you can upgrade it to cache.r5 which offers improved performance.
Note: We recommend that you test any changes on a test instance before modifying a production instance so that you fully understand the impact of each change. Testing is especially important when upgrading database versions.
*Resource information Listed below*
Affected Service Dependencies:
EC2 instances
Elastic Load balancers
Snapshot
Implementation Plan:
Pre Requisites:
Should have cache.r4 Node type
Approval Required from the client for the downtime of the instance
Make sure all the configurations are noted
Perform Backup for restoration
Current Status: (Check which Instance type is using currently)
Log in to the AWS Management Console.
Navigate to ElastiCache dashboard at https://console.aws.amazon.com/elasticache/.
Click on Memcached to access the clusters created with Memcached in-memory cache engine or Redis to access the clusters created with Redis engine, under ElastiCache Dashboard, In the left navigation panel
Select the cluster that you want to examine and click on it
Click on the Description tab, You can find the current Node type from the details shown
Implementation steps:
Log in to the AWS Management Console.
Navigate to ElastiCache dashboard at https://console.aws.amazon.com/elasticache/.
Click on Memcached to access the clusters created with Memcached in-memory cache engine or Redis to access the clusters created with Redis engine, under ElastiCache Dashboard, In the left navigation panel
Select the cluster that you want to upgrade
Click on the Actions button on top and select Modify
Modify Cluster window will open, there click on the down arrow in node type option
By clicking on the down arrow you will get all the options available, from the options select cache.r5 node type
- Select one of the cache.r5 node type and click on checkBox in the bottom to schedule modification and then click Modify
Status after Implementation:
The Node type column of the particular cluster that you changed has to show the type that you selected i.e, cache.r5 Follow the steps of the current status to check.
Make sure the Node type that you changed(cache.r5) is shown in the Node type column.
Back Out Plan: (If you want to rollback to the previous type)
If you want to roll back to the previous Node type at any moment, just follow the steps that you followed in the Implementation steps section, and then in the step where we want to choose Node type, select cache.r5 type node for the rollback.
Perform restoration in case of any disaster
Log in to the AWS Management Console.
Navigate to ElastiCache dashboard at https://console.aws.amazon.com/elasticache/.
Click on Memcached to access the clusters created with Memcached in-memory cache engine or Redis to access the clusters created with Redis engine, under ElastiCache Dashboard, In the left navigation panel
Select the cluster that you want to Backup
Click on the Actions button on top and select Backup
- If you want to restore from the backups, click on the Backups on the left navigation pane
- Select the backup you want to restore and click on the Restore option the top
Note: Keep the backup for 5 business days before discarding it.
Reference:
Comparing Memcached and Redis - Amazon ElastiCache for Redis
Choosing your node size - Amazon ElastiCache
Total Cost Savings(Yearly)
Pricing examples
Product Details - t2.*
t2 instances are a low-cost, general-purpose instance type that provides a baseline level of CPU performance with the ability to burst above the baseline when needed. With On-Demand Instance prices starting at $0.0058 per hour
Name | vCPUs | RAM (GiB) | CPU Credits/hr | On-Demand Price/hr* | 1-yr Reserved Instance Effective Hourly* | 3-yr Reserved Instance Effective Hourly* |
---|---|---|---|---|---|---|
t2.nano | 1 | 0.5 | 3 | $0.0058 | $0.003 | $0.002 |
t2.micro | 1 | 1.0 | 6 | $0.0116 | $0.007 | $0.005 |
t2.small | 1 | 2.0 | 12 | $0.023 | $0.014 | $0.009 |
t2.medium | 2 | 4.0 | 24 | $0.0464 | $0.031 | $0.021 |
t2.large | 2 | 8.0 | 36 | $0.0928 | $0.055 | $0.037 |
t2.xlarge | 4 | 16.0 | 54 | $0.1856 | $0.110 | $0.074 |
t2.2xlarge | 8 | 32.0 | 81 | $0.3712 | $0.219 | $0.148 |
*Prices shown are for Linux/Unix in US East (Northern Virginia) AWS Region. Prices for 1-year and 3-year reserved instances are for "Partial Upfront" payment options or "No upfront" for instances without the Partial Upfront option. For full pricing details, see the Amazon EC2 pricing page.
Product Details - t3a.* instances
The t3a.* instances feature AMD EPYC, 7000 series processors, with an all-core turbo clock speed of 2.5 GHz. The AMD-based instances provide additional options for customers that do not fully utilize the compute resources and can benefit from a cost savings of 10%.
$Name | vCPUs | Memory (GiB) | Baseline Performance/vCPU | CPU Credits earned/hr | Network burst bandwidth (Gbps) | EBS burst bandwidth (Mbps) | On-Demand Price/hr* | 1-yr Reserved Instance Effective Hourly* | 3-yr Reserved Instance Effective Hourly* |
---|---|---|---|---|---|---|---|---|---|
t3a.nano | 2 | 0.5 | 5% | 6 | 5 | Up to 2,085 | $0.0047 | $0.0028 | $0.0019 |
t3a.micro | 2 | 1.0 | 10% | 12 | 5 | Up to 2,085 | $0.0094 | $0.0056 | $0.0038 |
t3a.small | 2 | 2.0 | 20% | 24 | 5 | Up to 2,085 | $0.0188 | $0.0112 | $0.0075 |
t3a.medium | 2 | 4.0 | 20% | 24 | 5 | Up to 2,085 | $0.0376 | $0.0224 | $0.0150 |
t3a.large | 2 | 8.0 | 30% | 36 | 5 | Up to 2,780 | $0.0752 | $0.0449 | $0.0301 |
t3a.xlarge | 4 | 16.0 | 40% | 96 | 5 | Up to 2,780 | $0.1504 | $0.0898 | $0.0602 |
t3a.2xlarge | 8 | 32.0 | 40% | 192 | 5 | Up to 2,780 | $0.3008 | $0.1796 | $0.1203 |