Skip to main content

CRE-2025-0173

Redis Connection Timeout and Connectivity IssuesCritical
Impact: 10/10
Mitigation: 7/10

CRE-2025-0173View on GitHub

Description

Detects Redis connection timeout errors and connectivity failures that prevent clients from establishing or maintaining connections to the Redis server. These issues commonly occur during high load, network problems, or server resource exhaustion.\n

Mitigation

IMMEDIATE ACTIONS:\n- Verify Redis server is running: `systemctl status redis`\n- Test connectivity: `redis-cli -h ‹host› -p ‹port› ping`\n- Check current connections: `redis-cli CLIENT LIST | wc -l`\n- Review max clients setting: `redis-cli CONFIG GET maxclients`\n\nRECOVERY:\n- Restart Redis service if unresponsive:\n `systemctl restart redis`\n- Increase connection timeout in client:\n `redis.conf: timeout 300`\n- Kill idle connections:\n `redis-cli CLIENT KILL TYPE normal`\n- Increase max clients limit:\n `redis-cli CONFIG SET maxclients 10000`\n\nNETWORK TROUBLESHOOTING:\n- Check firewall rules: `iptables -L -n`\n- Test network connectivity: `telnet redis-host 6379`\n- Verify DNS resolution: `nslookup redis-host`\n- Check for packet loss: `ping -c 100 redis-host`\n\nPREVENTION:\n- Implement connection pooling with proper sizing\n- Configure appropriate timeout values\n- Monitor connection metrics and set alerts\n- Use Redis Sentinel or Cluster for high availability\n- Implement circuit breaker pattern in clients\n- Regular load testing and capacity planning\n

References