Dragonfly Cloud is now available on the AWS Marketplace - Learn More

Error: elasticache redis create-failed

Resolving "ElastiCache Redis Create-Failed" Error

This error occurs when AWS fails to create a Redis cluster in ElastiCache. Here are specific steps to diagnose and resolve the issue.

Immediate Diagnostics

  1. Check CloudWatch Logs

    • Navigate to CloudWatch in AWS Console
    • Look for ElastiCache logs
    • Search for specific error messages related to the failed creation
  2. Review AWS Service Health Dashboard

    • Visit https://status.aws.amazon.com/
    • Check for any ongoing issues in your region

Common Causes and Solutions

  1. Insufficient VPC Resources

    • Error: "Insufficient free addresses in subnet"
    • Solution:
      • Go to VPC Dashboard
      • Select your subnet
      • Check "Available IPs"
      • If low, expand CIDR range or use a different subnet
  2. Incompatible Subnet Configuration

    • Error: "The specified subnet is in an unsupported Availability Zone"
    • Solution:
      • Ensure subnet is in an AZ that supports ElastiCache
      • Use AWS CLI to check supported AZs:
        aws elasticache describe-cache-subnet-groups
        
  3. Security Group Issues

    • Error: "Security group not found" or "Invalid security group ID"
    • Solution:
      • Verify security group exists and is correctly configured
      • Ensure inbound rule allows traffic on port 6379 (default Redis port)
  4. Parameter Group Incompatibility

    • Error: "Invalid parameter group"
    • Solution:
      • Check if parameter group is compatible with chosen Redis version
      • Create a new parameter group if necessary:
        aws elasticache create-cache-parameter-group --cache-parameter-group-family redis6.x --cache-parameter-group-name custom-redis-params --description "Custom Redis params"
        
  5. Service Limit Reached

    • Error: "Max number of cache clusters reached"
    • Solution:
      • Check current limits:
        aws service-quotas get-service-quota --service-code elasticache --quota-code L-7132A81C
        
      • Request limit increase via AWS Support Center
  6. Insufficient IAM Permissions

    • Error: "User: arn:aws:iam::... is not authorized to perform: elasticache:CreateCacheCluster"
    • Solution:
      • Review IAM policy attached to your user/role
      • Ensure it includes necessary ElastiCache permissions:
        { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": "elasticache:CreateCacheCluster", "Resource": "*" } ] }

Step-by-Step Troubleshooting

  1. Gather Error Details

    • Use AWS CLI to get detailed error message:
      aws elasticache describe-cache-clusters --cache-cluster-id your-cluster-id
      
  2. Check Network Configuration

    • Verify VPC, subnet, and security group settings
    • Ensure ElastiCache can communicate with necessary services
  3. Validate ElastiCache Configuration

    • Review chosen Redis version, node type, and parameter group
    • Ensure compatibility between these settings
  4. Examine Resource Limits

    • Check if you've hit any AWS account limits for ElastiCache
  5. Verify IAM Permissions

    • Ensure your IAM user/role has sufficient permissions for ElastiCache operations
  6. Retry Creation

    • If all checks pass, try creating the cluster again
    • Use a different name to avoid cached errors

If the issue persists after these steps, contact AWS Support with the specific error messages and the steps you've taken. They can provide more targeted assistance based on your account and configuration.

Was this content helpful?

Switch & save up to 80% 

Dragonfly is fully compatible with the Redis ecosystem and requires no code changes to implement. Instantly experience up to a 25X boost in performance and 80% reduction in cost