Conversation
Signed-off-by: Dani Pletter <dpletter@users.noreply.github.com>
This branch has not been deployed
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.
Description
Adds an optional
balloonblock to a pool'sfirecrackerconfig that attaches Firecracker's memory balloon device to each MicroVM before boot.FirecrackerBalloonConfigwithamount_mib,deflate_on_oom,stats_polling_interval_sandfree_page_reporting. It is validated (no negative values). Without the block, MicroVMs are created exactly as before.PUT /balloonon the Firecracker API socket, added to theFcInithandler list. The SDK's balloon model has nofree_page_reportingfield, so it cannot express the option that makes the balloon useful here.free_page_reporting: true, memory the guest frees goes back to the host continually. Without it, a MicroVM keeps its peak memory until it exits.CONFIG_VIRTIO_BALLOON, andCONFIG_PAGE_REPORTINGfor free page reporting).Verified on Firecracker 1.16.1 with a 6.1 guest kernel. After the guest filled and freed 1.2 GB, host RSS of the Firecracker process fell from 1277 MiB to 83 MiB within 10 seconds; with no balloon it stayed at 1277 MiB. It has run on a production CI host with two pools since 2026-09-26.
Related Issue(s)
Closes #347
Checklist