Skip to content

[linux][P2] bridge network backend (passt) crash leaves the box running/healthy with no event — networking (incl. peer traffic) is silently dead #454

Closed

Description

@CharlieZiChen

Environment

  • A3S Box origin/main e06137de (v3.2.6), built from source; vendored libkrun daec6e8, libkrunfw v5.3.0
  • Ubuntu, kernel 6.17.0-23-generic, x86_64, KVM, unprivileged user; passt 2026_07_16.090d739
  • a3s-box network create <net> (bridge driver) + two MicroVM boxes on it

Summary

When the per-box passt process dies (SIGKILL here; in production: OOM, crash, accidental pkill), the box loses
all networking — not only egress through passt, but also peer-to-peer traffic on the bridge network, because the
shim's peer switch thread exits with the passt connection and unlinks its switch socket. Yet nothing the user can query
reflects this:

surface after passt died
inspect "status": "running", "health_status": "none", "exit_code": null (checked at +1 s, +6 s, +11 s)
ps running
events --since <kill time> no event
stats --no-stream normal CPU / MEM / NET I/O counters
a3s-box monitor nothing to do — the box is not dead
boxes/<id>/logs/shim.stderr.log the only trace (see below)

docs/soak-test-plan.md § Fault Catalog lists this exact fault with the expected outcome
"F06 netproxy/passt termination … Existing failure is visible; cleanup closes ports/routes; later workloads recover".
The "visible" clause is not met; the "recover" clause is (a manual restart fixes it).

Reproduced 4/4.

Steps to reproduce

a3s-box network create n1
a3s-box run -d --name br1 --network n1 alpine:test -- /bin/sh -c \
  'while :; do { printf "HTTP/1.1 200 OK\r\nContent-Length: 3\r\nConnection: close\r\n\r\nbr1"; } | nc -l -p 8093; done'
a3s-box run -d --name br2 --network n1 alpine:test -- sleep 3600
a3s-box exec br2 -- wget -T5 -qO- http://br1:8093/          # -> br1   (peer path works)

ID=$(a3s-box inspect br1 | jq -r .id)
kill -9 $(pgrep -f "passt --socket /tmp/a3s-box-sockets/$ID/")

a3s-box exec br2 -- wget -T5 -qO- http://br1:8093/          # -> download timed out
a3s-box inspect br1 | jq '{status, health_status}'          # -> running / none
a3s-box events --since 30s                                  # -> nothing
ls /tmp/a3s-box-switches/$(id -u)/*/                        # -> br1's <mac>.sock is gone, br2's remains
grep -n FATAL $A3S_HOME/boxes/$ID/logs/shim.stderr.log

shim.stderr.log:

LIBKRUN VIRTIO-NET FATAL: Backend process seems to have quit or crashed! Networking is now disabled!
[2026-09-16T07:44:56Z ERROR devices::virtio::net::worker] Failed to process tx: Backend(ProcessNotRunning)
[2026-09-16T07:44:57Z ERROR devices::virtio::net::worker] Failed to process tx: Backend(ProcessNotRunning)
...   (one line per second, forever)

Why peer traffic dies too

netproxy/src/passt_bridge.rs::run_passt_bridge returns
Err(BrokenPipe("passt closed its guest connection")) on passt EOF; the BridgePort is dropped and its
/tmp/a3s-box-switches/<uid>/<net>/<mac>.sock removed (device.rs impl Drop for BridgePort). From then on peers'
send_to for that MAC fails, so the box is unreachable on the bridge even though peer frames never needed passt.
The guest itself is fine (exec works, listener still up, wget http://127.0.0.1:8093/ inside br1 succeeds).

Expected

At least one of:

  1. The shim reports the backend loss to the runtime → inspect shows a degraded state (e.g. network_status: "backend_lost" or health_status: "unhealthy"), and an event (network_backend_died / unhealthy) is emitted so
    events, monitor and --restart policies can act.
  2. The shim re-spawns passt (it owns the socket path, IP, MAC and port map) and re-attaches the peer switch, logging a
    warning — mirroring how monitor handles dead boxes.
  3. Failing both, docs/soak-test-plan.md F06 should not promise visibility, and the CLI reference should document that
    backend death is only observable in shim.stderr.log.

Evidence

evidence/w11/n11/: run-n11.sh (harness), trial-{1,2,3,4}-user/run.log, inspect-after.json, events.txt,
summary.md; run-restart-probe.sh + restart-probe-* show restart recovers (peer switch socket re-created,
br2 → br1 OK).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions