Repository navigation
fix(runtime): fence expired runc startup and retain failed deletions - #99
Conversation
Advance sandboxd to prevent runc startup after cold image preparation outlives the create deadline. Missing containers also reclaim empty runc state directories while preserving nonempty state and symlinks. Keep the ADX build #161 artifact pins and TLS policy unchanged. Signed-off-by: robbluo <luo1442@gmail.com>
Advance sandboxd to preserve runtime and filesystem ownership when runc cannot execute or cleanup fails. Add an opt-in standalone fault regression that removes runc, checks retained metadata and resources, restores it and waits for adxlet monitoring to clean up without another public deletion. Keep the final catalog-record cleanup distinct from automatic physical cleanup, and document the isolated container identity requirements. Signed-off-by: robbluo <luo1442@gmail.com>
Gate executable-loss injection on explicit container name and identity fixtures as well as the global fault opt-in. Other full fault campaigns can then skip this standalone-only case without failing on missing Docker fixture settings. Signed-off-by: robbluo <luo1442@gmail.com>
|
@WenYuLuo Please address these two P2 recovery gaps in the new fault test before merging. This review covers HEAD 1. A completed rename with a failed Docker completion skips restoration. At I executed the actual reviewed test method with Docker/Redis/HTTP replaced by controlled fakes. The Docker substitute renamed a task-local dummy file and then raised Please persist recovery intent before mutation, including the exact container ID and original/backup paths, and make restoration idempotent based on the actual checked filesystem state rather than only a post-success Boolean. Setting the Boolean earlier alone is insufficient when the rename never happened. Use the full verified container ID for recovery actions, preserve unexpected replacements, and ensure final evidence is written even if restoration or catalog cleanup raises; the current JSON write at lines 299–301 can also be skipped by an earlier cleanup exception. 2. The runner can kill the only restoration owner while runc is hidden. The new case registration at Reproduced with the actual runner and actual test method, a two-second aggregate budget, fully simulated endpoints and task-local dummy files: Please reject destructive injection when insufficient execution/restoration budget remains, and provide restoration outside the child that may be killed, such as a parent-side recovery guardian/hook using the exact fixture ID and durable recovery record. Record restoration completion/failure separately from the timed-out test result. A child-only Suggested regressions for these paths:
The tightened gate correctly skips when required fixture/integration/fault variables are missing; six independent missing-variable checks made no Docker/API calls. The normal source control flow correctly separates automatic-cleanup observations from final catalog retirement. These positives do not cover the exceptional recovery paths above. Evidence boundaries: the recovery reproductions are simulated control-flow tests, not a live native-runc fault-E2E pass. Exact-head AKernel CI has 10 successful checks and the expected publish skip; local SDK unit/benchmark/Ruff/mypy and deployment syntax checks pass. Default Standalone E2E builds with runc disabled and does not exercise this opt-in full-level case. I independently fetched sandboxd Please fix and merge sandboxd #74 first, then verify this PR's final dependency SHA/code equivalence, final test/recovery-file fingerprints and updated CI, and rerun the corrected fault test on a verified exclusive fixture. AKernel #96 continues tracking the remaining cleanup semantics and real-workload/guest acceptance. This round did not execute cold imports, live cancellation cleanup, KVM/QEMU or macOS guest acceptance. |
|
@WenYuLuo Follow-up review against the still-current HEAD The 305-line fault test is unchanged, SHA-256 P2 — a successful rename with a failed Docker completion still skips restoration At Please persist recovery intent before mutation, including the full verified container ID and original/backup paths. Restore idempotently from the checked filesystem state, preserve unexpected replacements, and verify the restoration outcome. Merely setting the Boolean earlier does not cover the opposite case where the rename never happened. Recovery actions should use the full verified ID rather than relying on the mutable container name. P2 — the runner still kills the sole restoration owner on timeout The new case registration at Please reject destructive injection when insufficient execution/restoration budget remains and add restoration outside the child that may be killed, such as a parent-side recovery hook/guardian backed by the exact fixture ID and durable recovery intent. Record restoration success or unresolved recovery failure separately from the timed-out test result. A child-only Evidence preservation and required regressions I additionally simulated restoration failure and final catalog-cleanup failure separately. Both correctly raise a unittest error, but either can bypass the final JSON write at Please add maintained regressions that cover:
Final dependency and merge order The gitlink still pins sandboxd The #74 follow-up review passed independent local format/vet/full unit/runc-shim-server race checks and verified real-runc diagnostic probes; its current CI has all 14 checks successful. I now recommend Approve for #74. Please merge it first, then pin its final squash commit in #99 or verify actual tracked-tree equivalence of the chosen dependency. Fix the two recovery gaps, verify final test/recovery-file fingerprints and updated-head CI, and rerun the corrected opt-in native-runc fault case on a verified exclusive deployment. No duplicate repair PR is needed from our side. The ADX source pin and actual platform/Execd archive inputs remain consistent; the previously downloaded exact official archive bytes were rehashed this round. No new complete AKernel image build or live fault E2E was performed. The historical author-reported Linux/native-runc campaign remains author evidence for the earlier source tree, not this round's live acceptance. Default Standalone CI explicitly builds with runc disabled and does not exercise this full-level opt-in group. AKernel #96 continues tracking remaining cleanup semantics, integration and real-workload/guest acceptance. Cold OCI import, real cancellation cleanup, AKernel KVM/QEMU/macOS guest acceptance were not run in this round. Delete ACK, logical Deleted, empty inventory and completed physical release are separate evidence levels; neither this PR's green CI nor final explicit catalog deletion closes that acceptance scope. |
|
@WenYuLuo Dependency update: sandboxd #74 has now been squash-merged as #99 is still at The #74 dependency is now merged; the remaining #99 review requirements are unchanged. This is an integration-status update only, not a formal approval or a new runtime acceptance claim. AKernel #96 continues tracking remaining cleanup semantics, integration and real-workload/guest acceptance; default CI does not replace the opt-in fault case, cold-import/cancellation cleanup or KVM/QEMU/macOS guest validation. |
Consume a sandbox- and daemon-scoped fault token before returning the selected delete failure. Keep the native binary available for all other commands, later retries and restarted daemons. Observe retained ownership at the next real delete and keep catalog retirement separate from cleanup. Reject injection with insufficient campaign budget and write final evidence when test cleanup raises. Cover atomic one-shot consumption, unrelated commands, expiry, restart and controller timeout with real subprocesses. Advance sandboxd to the reviewed classification fix used for live validation. Signed-off-by: robbluo <luo1442@gmail.com>
Advance the sandboxd submodule to the official main commit containing PR inclusionAI#74. Its tracked tree matches the native-runc build used for the one-shot delete fault validation, preserving the tested runtime behavior. Signed-off-by: robbluo <luo1442@gmail.com>
|
@rcyw Updated in Fault scope and cleanup The injector now fails exactly one selected The fixture installs a ready, default-pass launcher atomically and preserves an unchanged copy of native runc. Both possible installation outcomes leave a working executable path, so the test does not depend on its child process moving a missing executable back. The runner rejects this group with less than 120 seconds remaining; the child checks at least 100 seconds before arming. Docker mutations use the verified full container ID. Disarming and catalog-cleanup errors are collected before the final JSON evidence write. Dependency
Regression results
Tested SHA-256 fingerprints match the final Python sources:
#96 remains open for its separate cleanup-timing, original-workload and guest/macOS acceptance scope. This report distinguishes the actual opt-in native-runc run from default CI; it does not claim fresh cold-import/cancellation or KVM/QEMU/macOS guest acceptance. |
Cold OCI preparation could start runc after the create deadline, and runtime deletion errors could be mistaken for successful absence. Pin sandboxd official-main commit
d5886b42ceff89bf0bf9baf7f73f5c534f689dee, including merged sandboxd #72 and #74. Runtime deletion failure retains metadata, mounts/private storage and resource ownership for subsequent attempts.The opt-in
fault-runc-delete-retrycase now fails exactly one selected runc delete invocation. An atomic default-pass launcher delegates to an unchanged copy of real runc. A five-second token matches the exact physical sandbox/delete arguments and original sandboxd process identity, and is consumed before returning the injected error. Other commands and later deletes execute real runc; a daemon restart invalidates any pending token. Installation atomically replaces a valid executable path with a ready launcher, so an unknown Docker completion does not require moving a missing binary back. The exclusive fixture is destroyed after validation.The case captures retained metadata/private-file hashes, namespace/cgroup and ADX held/assignment evidence at the following real delete, then only polls physical/Redis cleanup without another public DELETE. A final explicit operation retires the remaining catalog record separately. The runner rejects this group with under 120 seconds of remaining budget; the child checks at least 100 seconds before arming. Final evidence is written even when disarming or catalog cleanup raises. Unit regressions cover exact matching, concurrent single consumption, expiry, daemon replacement, a controller killed after injection and insufficient campaign budget.
Validation of the maintained fault code at
fe2ae123972bc382352a54679c6be53d6b407cbe; final gitlink-only update at579646f6f2f85e21f7d212a324d879716218b993:adx_environment; the complete passing check used the established #161 validation virtualenv, with the failed environment log retained.9ed03b...was used as the base, replacing only sandboxd with a binary built from exact commit701887a; test imagesha256:e70dad071ee239041c61bf863a21e8ca05780f64624d73e2b303973688ac1d4d. Sandboxd and unchanged #161 ADX/Execd binary hashes were verified. Canonical official-main submodule checkout succeeded. Its tracked treeceb0e3ec035fe7db3922626db405a1a10f39d5b5is identical to the tested701887atree; the final pin changes only commit identity. All five tested Python file fingerprints match this commit.579646f, with publishing skipped as expected. Sandboxd feat: configure shared ChunkDB capacity in node deployments #74's reviewed head701887ahas all 14 CI checks passing at attempt 2, and the merged dependencyd5886b4has the identical tracked tree; the initial stats-output failure and denied initial rerun are retained in its historical evidence.Sandboxd #74 is merged. Related to #96; its Delete-ACK timing and original large-image/macOS/guest acceptance remain independent. ADX #161 artifact/source pins and default-disabled TLS verification are unchanged. This Linux/native-runc validation does not claim macOS/QEMU guest acceptance.