Repository navigation
isb 4.2.0: volumes left behind by removed sandboxes are cleaned up - #83
Merged
Merged
Conversation
A volume created by a plain sandbox (isb up, isb create, the SDK and MCP create) is labelled user.isb.sandbox. Once that sandbox is gone and nothing has the volume attached, isb serve deletes it after sandbox_volume_ttl (default 7d, none disables). keep: true on a volume definition opts out. isb volume prune lists and deletes them by hand, and --unattached covers unlabelled leftovers by name pattern. isbx removes a VM tool's cache volume with the tool, and isb x doctor notes a dir pool. Claude-Session: https://claude.ai/code/session_01LJ21XpNb5uQ2Ez9dt17GN8
Claude-Session: https://claude.ai/code/session_01LJ21XpNb5uQ2Ez9dt17GN8
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.
What
A volume created by a plain sandbox (
isb up,isb create, the SDK and MCPsandbox_create) is labelleduser.isb.sandbox. Once that sandbox is gone and nothing has the volume attached,isb servedeletes it aftersandbox_volume_ttl(default7d,noneturns it off).keep: trueon a volume definition opts a volume out (shared caches).isb volume prunelists volumes whose sandbox is gone;-ydeletes.--unattachedcovers unlabelled leftovers and needs name patterns to delete.isb sandbox settings --volume-ttl, andsandbox_volume_ttlon thesandbox_settingstool.isb x doctornotes adirpool (every sandbox a full copy of its image).Stack, app, database, job and backup volumes,
isb volume createvolumes andexternalvolumes are never labelled or swept.Why
On a host with a
dirpool, per-sandbox cache volumes (${SANDBOX_NAME}-modules) outlived their sandboxes forever: about 100 GB on titan.Verified
scripts/check.shgreen in a sandbox;tests/volume_owner.rsintegration tests pass against real incus.https://claude.ai/code/session_01LJ21XpNb5uQ2Ez9dt17GN8