| « PreviousNext » | |
![]() ![]() ![]() | Did this page help you? Yes | No | Tell us about it... |
One of the advantages of ElastiCache is that you can easily select and change the amount of memory and compute capacity available in your cache cluster. This topic will assist you in the process of choosing the initial capacity of your cache cluster and show you how to change the capacity in existing cache clusters.
The total memory capacity of your cache cluster is calculated by multiplying the number of cache nodes in the cluster by the capacity of each Node. The capacity of each cache node is based on the cache node type.
The number of cache nodes in the cache cluster is a key factor in the availability of your cache cluster. The failure of a single cache node can have an impact on the availability of your application and the load on your backend database while ElastiCache provisions a replacement for the failed cache node. The scale of this availability impact can be reduced by spreading your memory and compute capacity over a larger number of cache nodes, each with smaller capacity, rather than a fewer number of high capacity nodes.
In a scenario where you want to have 20GB of cache memory, you can set it up in one of the following ways:
Use 15 cache.m1.small cache nodes with 1.3 GB of memory each = 19.5
GB
Use 3 cache.m1.large cache nodes with 7.1 GB of memory each = 21.3
GB
Use 3 cache.c1.xlarge cache nodes with 6.6 GB of memory each = 19.8
GB
These options provide you with similar memory capacity, but different computational capacity for your cache cluster.
Note
Some of the available memory on each cache node will be used for connection overhead. For more information, see the section Understanding and Tuning Memcached Connection Overhead.
If you're unsure about how much capacity you need, we recommend starting with one
cache.m1.small cache node type and monitoring the memory usage, CPU
utilization and Cache Hit Rate with the ElastiCache metrics that are published to Amazon
CloudWatch.
If your cache cluster does not have the desired hit rate, you can easily add more nodes, thereby increasing the total available memory in your cache cluster. You will need to obtain an updated endpoint list from the ElastiCache CLI, API or AWS Management Console, and configure your clients to use the additional node(s).
If your cache cluster turns out to be bound by CPU but has sufficient hit rate, then try setting up a new cluster with a different cache node type.
ElastiCache supports adding or removing cache nodes from an existing cache cluster using the AWS Management Console, the API, and the command line tools, allowing you to increase both memory and compute capacity of the cluster at any time.
Note
ElastiCache does not currently support dynamically changing the cache node type for a cache cluster after it has been created. If you wish to change the Node Type of a cache cluster, you will need to set up a new cache cluster with the desired Node Type, and migrate your application to that cache cluster.
For more information about how to scale cache clusters using the API, the command line tools, or the AWS Management Console, see Scaling a Cache Cluster.