Teardown observability: a quarantined VM reports power_state=running with all actual-state fields blank #74
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
[claude 2026-08-21] Found while tearing down the demo VMs on onyx. A tombstoned
VM spends 5 minutes (
-tombstone-grace, internal/agent/run/cli.go:138) inquarantine before its disk is destroyed. During that window the API reports the
VM in a way that actively misleads:
power_statestill readsrunning— that is stale DESIRED state. The agenthas already called
Prov.Shutdown(internal/agent/reconcile/reconcile.go:481);the guest is off within seconds of the DELETE.
phase,actual_powerandstatus_detailall go EMPTY. reconcile.go:350-352puts quarantined VMs in
Quarantined[]rather thanVms[], so the server hasno ActualVM for them and every actual-state field blanks — precisely during the
one window where the operator most wants to know what teardown is doing.
Net effect: for 5 minutes the console and API say "running", with no phase and no
detail, for a guest that is already stopped and counting down to disk destruction.
Repro
Why it matters
I misread this as a stalled teardown and went looking for agent logs. The only
in-band signal that the agent had actually acted was the host's
allocateddropping (releaseCompute runs at quarantine) — which requires knowing to check a
different endpoint and knowing each VM's shape to do the arithmetic.
destroy_atis present and correct, so the countdown IS on the wire; thesurrounding fields just contradict it.
Suggested shape (not decided)
A
phase=quarantined(orstopping/draining) withstatus_detailcarrying thecountdown would answer the question directly. Whether that means synthesising an
ActualVM for quarantined VMs server-side, or widening the Quarantined[] entry, is
the design question. Note the wire has a field-NUMBER lock (#32) — a new field
needs a fresh number.
Migrated from git-collab issue
5a39478b47db30b9a632f01af37bfb01f498951e.Original author: a73x dev@a73x.sh.