Repository navigation
Description
Warning
Regression — broken in v0.0.128, and in v0.0.121 before it. The fix merged for #11418 does not cover the failure window this symptom occurs in, and the two commands involved now deadlock each other.
Note
Re-verified reopening of #11418 — closed via #12083 (merge commit b75e35669, confirmed an ancestor of v0.0.128). Re-verification on v0.0.128 reproduces the original failure state and finds no supported way out of it. See the QA verify comment on the linked NVBug for the full repro transcript.
Description
When sandbox creation fails after the image builds but before the pending-create identity is published to the registry, the sandbox is left with a retained-recovery record that no supported command can reconcile. destroy refuses to act, and onboard refuses to reuse or recreate the name until destroy completes — so the two commands point at each other and the user cannot proceed with that sandbox name at all.
The refusal message is more structured than in v0.0.121 and now cites a recovery record ID, but it states outright that this build has no supported automatic repair. Clearing the state required hand-editing product state files.
The fix merged for the earlier issue adds a reconstruction step that rebuilds the retained-recovery record from the registry's pending-create identity. That identity is precisely what this failure window never publishes, so the reconstruction is skipped and the deadlock is unchanged.
Platform scope: Reproduced on Ubuntu 26.04 x86_64 only; other platforms not tested in this pass.
Regression: Yes — reported and fixed against v0.0.121, still reproduces on v0.0.128.
OpenShell issue: No
Environment
Device: Linux x86_64 server
OS: Ubuntu 26.04 LTS
Architecture: x86_64
OpenShell CLI: openshell 0.0.116
NemoClaw: nemoclaw v0.0.128
OpenClaw: N/A (sandbox creation did not complete)
Steps to Reproduce
- Build a sandbox image that builds cleanly but whose container fails immediately at start, so the failure lands after image build and before the pending-create identity is published:
FROM ghcr.io/nvidia/nemoclaw/sandbox-base:v0.0.128
ARG NEMOCLAW_TOOL_DISCLOSURE=progressive
ENV NEMOCLAW_TOOL_DISCLOSURE=$NEMOCLAW_TOOL_DISCLOSURE
RUN echo "BASELINE_BUILD_OK"
RUN printf %s 'case "$0" in */nemoclaw-start) echo "...libnvidia-ml.so.1: cannot open shared object file..." >&2; exit 127;; esac' > /opt/startfail.sh && chmod 0644 /opt/startfail.sh
ENV BASH_ENV=/opt/startfail.sh- Onboard from that Dockerfile:
nemoclaw onboard --from <dir>/Dockerfile --name <sandbox> --non-interactive --fresh --yes- Confirm which failure variant you are in — the registry row must have no pending-create identity:
cat ~/.nemoclaw/retained-sandbox-recovery.json
cat ~/.nemoclaw/sandboxes.json- Try every supported way to clear it:
nemoclaw <sandbox> destroy --yes
nemoclaw <sandbox> destroy --force
nemoclaw <sandbox> doctor --fix
openshell --gateway <gateway> sandbox delete <sandbox>
nemoclaw onboard --name <sandbox> --non-interactive --fresh --yesExpected Result
A user whose sandbox creation failed can clear the leftover state and reuse that sandbox name, using documented commands only.
If the product genuinely cannot reconcile the record automatically, the refusal names a concrete action the user can take to get unblocked — not an instruction to preserve the state indefinitely, and not an instruction that points at another command which refuses for the reverse reason.
Actual Result
Step 2 — onboarding fails after a successful image build, exit 1:
Step 4/6 ... BASELINE_BUILD_OK
Sandbox image build completed in 30.1s
...
Error: Sandbox post-create verification or finalization failed; automatic sandbox cleanup was not safe.
Create-attempt label: ai.nvidia.nemoclaw.create-attempt=<label>.
Step 3 — the buggy variant is confirmed. retained-sandbox-recovery.json holds one record for the sandbox with "reason": "retained_after_sandbox_creation_failure", "identityWasUnavailable": false, plus a sandboxIdentityFingerprint and lifecycleGeneration. The sandboxes.json row carries only name, gatewayName and pendingRouteReservation: true — no pending-create identity and no lifecycleGeneration.
Step 4 — every supported path refuses.
destroy --yes, exit 1:
Cause: Refusing to destroy retained sandbox '<sandbox>' because NemoClaw could not select exactly one
recovery record from the current registry, onboarding session, and immutable recovery evidence.
Retained state: No sandbox resources were removed. The registry, onboarding session, and recovery
records remain unchanged.
Next action: Preserve this state and do not delete by mutable sandbox name. This build has no
supported automatic repair for conflicting recovery authority.
Diagnostic reference: retained recovery record ID <id>.
destroy --force → the identical refusal, exit 1.
doctor --fix → exit 0 but does not reconcile; reports Lifecycle registration: registry entry incomplete ... (missing dashboardPort, fromDockerfile, gatewayPort, imageTag, nemoclawVersion, openshellDriver, openshellVersion), and its only hint is "re-register or re-onboard".
openshell sandbox delete <sandbox> → exit 0 (✓ Deleted sandbox), but destroy afterwards gives the identical refusal, exit 1. This is the remedy that clears the other variant of this failure; it does not help here.
onboard --fresh with the same name → exit 1:
Onboarding cannot use retained sandbox '<sandbox>' while its identity-bound recovery record is unresolved.
Run the destroy command for retained sandbox '<sandbox>' to remove the verified failed attempt; resume,
reuse, recreation, and same-name fresh onboarding remain disabled until destroy completes.
So onboard says to run destroy, and destroy says there is no repair and to preserve the state. There is no recovery or repair surface and no way to act on the cited record ID — destroy --help offers only --yes|-y|--force|--[no-]cleanup-gateway.
The state could only be cleared by hand-editing ~/.nemoclaw/sandboxes.json and ~/.nemoclaw/retained-sandbox-recovery.json.
Logs
Not captured beyond the terminal output quoted in Actual Result.
Activity
ChunkyMonkey11 commentedon Sep 24, 2026
@hulynn I read through #12083 and I think #12290 might be a similar problem, but in a slightly earlier failure case.
It looks like #12083 works when NemoClaw can still match the failed sandbox to the onboarding session. But in this issue, the sandbox fails before
pendingCreateIdentityis saved, and it seems like there is not enough matching session information left fordestroyto know which recovery record is safe to remove.Would it make sense to save the sandbox creation identity earlier, when the name is first reserved? That could include the sandbox name, gateway, identity fingerprint, lifecycle generation, and create-attempt nonce.
Then, if onboarding fails later,
destroycould compare that saved information with the recovery record before clearing it. This would still avoid deleting a newer sandbox that happens to have the same name, but it would give users a supported way to recover from this failed creation state.It might also be useful to add a test for this exact case: image build succeeds, sandbox startup fails before
pendingCreateIdentityis saved, anddestroycan safely clear the failed attempt after confirming the sandbox is gone.Would an OpenShell delete-by-identity feature help here too, or is saving this information earlier the better fix?
ChunkyMonkey11 commentedon Sep 24, 2026
@cv @hulynn I would like to take on this problem.
ChunkyMonkey11 commentedon Sep 26, 2026
PR #12331 is ready for maintainer review at head 2b040ce. Focused recovery and identity tests pass locally. Required checks are still in progress; I’ll confirm once they finish.
Mdlugopolski commentedon Oct 16, 2026
Related existing-state recovery case: missing identity and conflicting generations
I have a related retained-recovery blocker on NemoHermes 0.0.134. I am seeking a maintainer-supported way to retire the abandoned registration without deleting workloads, reconstructing missing authority, or affecting a separate environment. This is an existing-state diagnosis, not a clean-install reproduction of #12290.
Confirmed evidence
nemohermes upgrade-sandboxes --checkexits 1: one legacy registration is missing from its recorded gateway and receives generic destroy/onboard guidance.openshell sandbox list --gateway <legacy-gateway> --output jsonexits 0 and returns[]. This is a responding gateway with an empty inventory, not a failed observation.Environment and limitations
8a5718dd14a2c2e440011488b1f3a32e9414cf82, with pre-existing local modifications. This is not a claim that unmodified upstream reproduces every detail.Questions for maintainers
rebuild --retire-recovery <transaction-id>for a bound rebuild-policy-handoff transaction. Does that command apply to this distinct retained-sandbox authority conflict? I have not assumed that it does or run it.Required safety properties: preserve sibling records, the separate gateway environment, providers and backups; never invent identity/generation/cancellation proof; and do not enable unsafe same-name reuse by deleting a blocker. Archiving a record alone does not establish reconciliation.
Related upstream references checked
No change to a live sandbox or lifecycle authority is requested without a separately reviewed procedure.
wangericnv commentedon Oct 19, 2026
QA re-verification on v0.0.135: still reproduces verbatim
Re-ran this issue's own steps on v0.0.135 (Ubuntu 24.04 x86_64, Docker, OpenShell 0.0.116), using the Dockerfile from the report with only the base-image tag changed to
sandbox-base:v0.0.135, a dedicated gateway port and a fresh sandbox name.State after the failed onboarding is the same variant. One retained record with
reason: retained_after_sandbox_creation_failure,identityWasUnavailable: false, asandboxIdentityFingerprintand alifecycleGeneration. Thesandboxes.jsonrow has no pending-create identity (keys:credentialEnv, endpointSource, endpointUrl, gatewayName, hostLocalInferenceReceipt, model, name, pendingRouteReservation, preferredInferenceApi, provider, reservationSessionId).destroy --yesdestroy --forcedoctor --fixopenshell sandbox delete(thenopenshell sandbox listreturns[], no container, no volume), thendestroy --yesonboard --freshwith the same nameI also reproduced the same dead end twice more with a simpler trigger (an image whose entrypoint binary does not exist), on separate gateway ports.
Contrast with the identity-free variant. The case where OpenShell never returns a create identity (
identityWasUnavailable: true, null fingerprint) is cleared on v0.0.135 once absence is confirmed:destroyexits 0 with "Cleared retained recovery", unresolved records drop to 0, and the same name onboards again. So #13170 covers that variant, but not this one, where a durable identity fingerprint exists and the registry row is incomplete.PR #12331 ("fix(onboard): retain exact create identity receipts") is the open change aimed at this case; I have not tested it. Happy to re-run these steps against a build that includes it.
CoDev-BitByBit-Commit commentedon Oct 22, 2026
Reproduced on v0.0.137 through
rebuild, notonboardSame deadlock, reached through a different entry point. It still reproduces on v0.0.137 (
f00fb1da), OpenShell 0.0.116.Environment: DGX Spark (GB10, aarch64), Ubuntu, Docker driver gateway on a non-default port (8085), OpenClaw agent, provider
vllm(existing local server).Sequence:
spark-agentexists.nemoclaw spark-agent rebuild --yeswithNEMOCLAW_RAM=8g NEMOCLAW_CPU=4set.Sandbox 'spark-agent' was created, but OpenShell did not return one exact durable sandbox identity before post-create effects (selector-execution-uncoded-error).nemoclaw spark-agent rebuild --yes --tool-disclosure progressive(the command printed in the failure message) refuses:Rebuild cannot use retained sandbox 'spark-agent' while recovery record '…' is unresolved … Run 'nemoclaw spark-agent destroy --yes'.nemoclaw spark-agent destroy --yesrefuses:could not select exactly one recovery record from the current registry, onboarding session, and immutable recovery evidence … This build has no supported automatic repair for conflicting recovery authority.Why it deadlocks (from reading v0.0.137 source):
identityWasUnavailable: true, a nullsandboxIdentityFingerprint, and the newlifecycleGeneration.lifecycleGenerationandlifecycleLiveIdentityFingerprint, and nopendingCreateIdentity.reconcileIdentityFreeRecovery(actions/sandbox/lifecycle/retained-recovery.ts) returns early:unpublished(observedEntry)is false because the row still carries the old generation.selectRetainedSandboxRecoveryAuthority(actions/sandbox/destroy.ts) then compares the record's generation with the registry row's old generation. They differ and there is nopendingCreateIdentity, so nothing matches.retained-sandbox-recovery.jsonaside doesn't help:rebuildregenerates it from the session'scancellationRecovery.So for the rebuild path, the gap is that a recreate which has already destroyed the source never demotes or updates the registry row, and the identity-free reconciliation requires that row to be unpublished. Worth checking whether PR #12331 covers this path too.
Workaround that worked (no hand-editing of JSON):
~/.nemoclaw/gateways/<port>aside as a whole.openshell provider deletethe orphanednemoclaw-local-v1-*provider. Onboard otherwise refuses with "already exists without a matching NemoClaw ownership receipt".nemoclaw onboard --non-interactive. It reused the healthy gateway.The workspace has to be restored separately from the rebuild backup tarball.
The create failure itself appears to be triggered by
NEMOCLAW_RAM=8g(2/2 creates failed with8g; 4/4 succeeded with8Gi). I've filed that separately as #13623.fix(inference): onboard and replace pinned NVIDIA-compatible providers (
wscurran commentedon Nov 16, 2026
Hi Lynn, thanks for the careful testing and detailed report. We’re focusing development on NemoClaw V1 and don’t plan further work on this Classic report, so we’re closing it as not planned. We appreciate your contribution.