-
Notifications
You must be signed in to change notification settings - Fork 62
Description
When I set a memory limit for Redis pods using the provided redis-cluster chart, it appears to take the exact number I provide for the memory limit and place that in redis.conf on the maxmemory line. This neglects the overhead of Redis itself, the redisnode executable, and any other miscellanea that Kubernetes includes in its overhead accounting. In my setup, this adds up to about 40 MB that the container will use beyond Redis's memory limit. Thus, when Redis approaches capacity, the container's memory usage exceeds its configured resource limit, and Kubernetes kills the pod. I've been working around this by manually updating Redis's maxmemory to 100 MB less than the resource limit, which solves the problem. It would be nice if this could be automated so that resource limits work as expected.