Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

redis: bump memory requests/limits to 7 GB #2898

Merged
merged 2 commits into from
May 4, 2021
Merged

Conversation

ggilmore
Copy link
Contributor

@ggilmore ggilmore commented Apr 29, 2021

cc @mike-r-mclaughlin

Both redis-cache and redis-store have maxmemory 6gb in their redis.conf: https://github.com/sourcegraph/infrastructure/blob/main/docker-images/redis-cache/redis.conf#L4 and https://github.com/sourcegraph/infrastructure/blob/3d83a92ce64650f46754e2ac55c3accfe84ab0d7/docker-images/redis-store/redis.conf#L4. According to https://redis.io/topics/lru-cache#eviction-policies, redis will start evicting things from its cache once it hits that limit. However, because our k8s pod memory limits are also set to 6 GB - k8s will kill the redis pods before they have a chance to perform that eviction process.

Giving redis one more gigabyte to work with should give it enough room to do its cache eviction without being OOMKilled

@ggilmore ggilmore requested review from beyang and a team April 29, 2021 22:35
Copy link
Contributor

@daxmc99 daxmc99 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ggilmore ggilmore merged commit fe75ec0 into master May 4, 2021
@ggilmore ggilmore deleted the bump-redis-memory branch May 4, 2021 22:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants