Apply runtime kernel tweaks to memory allocation#712
Draft
Apply runtime kernel tweaks to memory allocation#712
Conversation
|
/rebase |
d993257 to
7afe809
Compare
7afe809 to
dc6856b
Compare
Contributor
Author
|
/rebase |
dc6856b to
93ac6bb
Compare
93ac6bb to
bdac383
Compare
There was a problem hiding this comment.
Pull Request Overview
This PR introduces runtime kernel memory management tweaks to address frequent "out of memory error 12" issues during firecracker VM startup by optimizing memory allocation behavior and cache reclamation.
- Adds a new
memory-tweaksservice that applies kernel memory tuning parameters - Configures aggressive memory compaction and higher minimum free memory thresholds
- Disables transparent hugepages to reduce memory fragmentation
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
These adjustments prefer writing to disk and reclaiming cache earlier in order to avoid the frequent "out of memory error 12" we have been experiencing on firecracker VM startup. We observed very large (50%) memory caches that were not freed up in time to start the next VM, so these settings will optimize for freeing the memory sooner. Change-type: minor Signed-off-by: Kyle Harding <kyle@balena.io>
bdac383 to
82ca20d
Compare
Signed-off-by: Kyle Harding <kyle@balena.io>
82ca20d to
3565fc4
Compare
Change-type: patch Signed-off-by: Kyle Harding <kyle@balena.io>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR introduces runtime kernel memory management tweaks to address frequent "out of memory error 12" issues during firecracker VM startup by optimizing memory allocation behavior and cache reclamation.
Change-type: minor
See: https://balena.fibery.io/Security/Information_Security_and_Reliability_Incident/GitHub-Runners-Failure-during-vcpu-run-Out-of-memory-(os-error-12)-130