Question: How Much Storage Does ElastiCache Redis Use?


ElastiCache for Redis uses storage based on the memory capacity of the selected node size. The actual amount of storage used depends on the data, data structures, and any additional overhead required by Redis.

To determine the storage capacity, you can select from a range of node types available in AWS. Each node type has different memory capacities, which directly affects the storage that ElastiCache Redis can use. Here is an example list of some common node types and their memory capacities:

  • cache.t2.micro: 0.555 GB
  • cache.t2.small: 1.55 GB
  • cache.t2.medium: 3.22 GB
  • cache.m4.large: 6.42 GB
  • cache.m4.xlarge: 13.5 GB

You can find the complete list of node types and their memory capacities in the official AWS documentation.

Keep in mind that not all of the memory is available for storing your data; Redis reserves a portion of it for internal processes. To store data in ElastiCache for Redis, you need to consider:

  1. The dataset size: Based on the size of your keys and values.
  2. Data structure overhead: Different data structures have different overheads (e.g., hashes, lists, sets).
  3. Key eviction policies: This affects how much of your data is stored before starting to evict older data.
  4. Memory fragmentation: Memory fragmentation may occur due to various operations taking place in Redis.

To monitor the current memory usage, run the INFO command, which provides statistics about memory utilization:> INFO MEMORY

This will return information including used_memory, used_memory_rss, and other memory-related metrics.

Was this content helpful?

White Paper

Free System Design on AWS E-Book

Download this early release of O'Reilly's latest cloud infrastructure e-book: System Design on AWS.

Free System Design on AWS E-Book
Start building today

Dragonfly is fully compatible with the Redis ecosystem and requires no code changes to implement.