Repository navigation
Description
Summary
On Linux/KVM (a3s-box v3.2.5 / Box revision c9a45455), a warm-pool daemon crash leaves pooled MicroVMs as orphan processes. Restarting the pool daemon does not reattach or reap them; pool stop, a3s-box ps -a, and system-prune cannot find the orphan VMs.
Severity: P1 (daemon crash leaks VM resources and pool capacity)
Acceptance case: B16 F03 pool-daemon crash recovery
Local tracking: N4
Expected
After a pool daemon restart, all VMs belonging to that pool must be identified and either reattached or reaped within a bounded period. pool stop and system-prune must operate on the recovered resources. No invisible orphan VM may remain.
Actual
The controlled runs show orphan shims after daemon restart:
N4c-1: after_daemon_kill_orphans=519453 519539 519729
after_daemon_restart_shims=519453 519539 520186
PRODUCT_FAIL N4: pool daemon restart did not reap orphan VMs
N4c-2: PRODUCT_FAIL N4: pool daemon restart did not reap orphan VMs
N4c-3: PRODUCT_FAIL N4: pool daemon restart did not reap orphan VMs
The surviving processes are exact shims whose command lines reference the test A3S_HOME; they are not unrelated host workloads.
Repro
export A3S_HOME="$(mktemp -d /var/tmp/a3s-n4.XXXXXX)"
export A3S_BOX=/path/to/Box/src/target/release/a3s-box
export A3S_BOX_TEST_ALPINE_TAR=/path/to/evidence/images/alpine-oci.tar
SOCK="$A3S_HOME/pool.sock"
a3s-box pool start --image alpine:defect-n4 --size 2 --max 2 \
--socket "$SOCK" --lease-ttl 10 &
# Wait until pool status reports idle=2.
kill -9 $!
sleep 3
# Restart the daemon and inspect the exact shim command lines.
a3s-box pool start --image alpine:defect-n4 --size 0 --max 2 --socket "$SOCK" &
sleep 5
ps -eo pid,ppid,args | grep "$A3S_HOME" | grep a3s-box-shim
# Actual: the orphan shims remain after daemon restart.Repro rate: 3/3 independent runs on 2026-09-14.
Environment
| Item | Value |
|---|---|
| OS | Ubuntu 24.04 x86_64 |
| Kernel | Linux 6.17 |
| Hypervisor | KVM / MicroVM |
| Binary | a3s-box 3.2.5 release |
| Commit | c9a45455ff59d53921e3abedffdfefd49eb0afa9 |
| Binary SHA-256 | b9783edb4881bbbcd968c10f539c746ac54bf5f05930309588cbe21db9eaa4b9 |
| Lane | Linux user lane; pool size 2; separate A3S_HOME and pool socket |
Evidence
evidence/w10/followup/reconfirm/batch1/N4c-1/confirm.logevidence/w10/followup/reconfirm/batch1/N4c-2/confirm.logevidence/w10/followup/reconfirm/batch1/N4c-3/confirm.logevidence/w10/followup/b16/orphan-check.logevidence/w10/followup/b16/summary.md
Regression coverage
Test idle VM, active VM, and client-disconnect daemon crashes. After restart, require bounded orphan reap or reattachment, consistent pool status/ps -a/pool stop results, and no remaining shim, VM, socket, mount, or pool-directory residue.
Activity
[-][linux] pool: daemon crash leaves orphan MicroVMs[/-][+][linux][P1] pool: daemon crash leaves orphan MicroVMs[/+]fix(pool): reap init-orphaned MicroVM shims on pool start
fix(pool): reap orphan MicroVMs on pool start (#373) (#376)
ZhiXiao-Lin commentedon Sep 14, 2026
Fixed by #376 (squash a94c18a). Pool start reaps orphan MicroVMs left after a daemon crash so inventory matches running VMs.
fix(cli): reap home-fenced orphan shims on pool stop (#384)