Full install on a Wi-Fi-only device is offered as "Most reliable" and then loses the box at kexec: the installer has no wireless link and the baked networkd config matches a Wi-Fi MAC — gate wireless-only hosts out of Full install at consent and befo… #2041

Closed
opened 2026-10-03 16:35:32 +00:00 by ben · 2 comments
Owner

Symptom (Whakatōhea Demo, device Delilah = node-req-0006, 2026-10-03 16:16–16:33Z)

Full-install Set up (backup copies + Genealogy) on a correctly enrolled device (mesh 100.83.245.38, root SSH from the gateway proven). The run reached the takeover's kexec phase, the box rebooted into the installer — and nothing ever came back:

clan: takeover of node-req-0006: the deploy target root@100.83.245.38 stopped answering during the kexec phase for 9 consecutive probes — reaping the phase (#1013)
provision deploy failed … kind=target_lost … before any disk work completed — the session was lost and never came back

The gateway's netbird-management journal shows no peer registration in the window (the installer is supposed to rejoin the mesh as a new peer with its node-scoped key, #1068), and the device's own peer went to Connecting and stayed there. The box is now headless in the Iwi office, running the RAM installer with no network — recoverable only by hands (power-cycle boots the untouched Ubuntu; no disk work ran).

Cause

Delilah's only link is a USB WiFi adapter (wlx00e02df33c46, 192.168.60.81/24); the wired port eno1 is DOWN. The enrolment probe (internal/hostprobe Network) records the default-route NIC by MAC with no notion of link type, the spec gate (internal/join/gate.go: spec-gate / virt-unavailable / arch-unsupported) never looks at it, and the P2-S3 menu offered Full install as "Most reliable". The takeover then:

  1. kexecs into the installer image, which has no wpa_supplicant and no credentials → no link → never rejoins the mesh → target_lost;
  2. would, had it installed, bake a MAC-matched systemd-networkd static config (renderNetworkd, enrollment.go:642) for the WiFi NIC's MAC — a wireless interface networkd cannot bring up → an offline NixOS box.

So a WiFi-only host can never complete a full install, and the product let the device owner consent to wiping it anyway. The fault is silent on the gateway (just a lost target) and silent on the device (no screen, no network).

Fix (proposed — two-way door, ADR 0174)

  1. Probe the link type. NetworkFacts gains Wireless bool (from /sys/class/net/<iface>/wireless or iw dev) for the default-route NIC, plus the list of wired NICs with carrier. Read-only, honest-empty when unreadable (ADR 0100).
  2. Gate it at consent. On P2-S3, a host whose default route is wireless and that has NO wired NIC with carrier is refused Full install with a typed rejection (RejectWirelessOnly): headline "This machine is on Wi-Fi only", Need = "a wired network connection the installer and the installed system can use without credentials", Got = "Wi-Fi () · wired port has no cable", Remedy = "plug in an Ethernet cable and choose Full install again, or choose VM mode" — code survives. VM mode stays offered (the guest rides the host's networking). Same rule in the app doorway (app.go) and the terminal (cli.go).
  3. Belt at deploy. Deploy/takeover refuses to start a takeover for a device whose recorded network facts are wireless-only (facts can change between consent and Set up — re-probe is the agent's; the control plane checks the last facts it holds) with the same words, before kexec — never a lost target.
  4. Honest failure copy. When a kexec phase loses the target and no installer peer registers within the window, the failure's detail says so: "the installer never reached the network — check the machine has a wired link; power-cycling boots the previous OS, no disk work ran" instead of the bare ssh timeout dump.
  5. Seam tests: wireless-only probe → full install refused, VM offered; wired-with-carrier → unchanged; takeover refused pre-kexec on wireless facts.

Recovery on the demo (needs hands at the office)

Power-cycle Delilah → it boots the untouched Ubuntu 26.04 (netbird reconnects to the community mesh, idss-agent.service returns). Plug in Ethernet to eno1 before any further Set up. The fleet row node-req-0006 is still enrolled; the failed run's recovery mode is rescue.

#2038, #2039, #2040 (same device, same day), #1013, #1068, ADR 0024, ADR 0209, ADR 0100, internal/hostprobe/prober.go, internal/join/gate.go, internal/join/cli.go, internal/provision/takeover.go, internal/clan/enrollment.go (renderNetworkd). GOTCHAS #392.

## Symptom (Whakatōhea Demo, device `Delilah` = node-req-0006, 2026-10-03 16:16–16:33Z) Full-install Set up (backup copies + Genealogy) on a correctly enrolled device (mesh 100.83.245.38, root SSH from the gateway proven). The run reached the takeover's **kexec phase**, the box rebooted into the installer — and nothing ever came back: ``` clan: takeover of node-req-0006: the deploy target root@100.83.245.38 stopped answering during the kexec phase for 9 consecutive probes — reaping the phase (#1013) provision deploy failed … kind=target_lost … before any disk work completed — the session was lost and never came back ``` The gateway's `netbird-management` journal shows **no peer registration** in the window (the installer is supposed to rejoin the mesh as a new peer with its node-scoped key, #1068), and the device's own peer went to `Connecting` and stayed there. The box is now headless in the Iwi office, running the RAM installer with no network — recoverable only by hands (power-cycle boots the untouched Ubuntu; no disk work ran). ## Cause Delilah's only link is a **USB WiFi adapter** (`wlx00e02df33c46`, 192.168.60.81/24); the wired port `eno1` is DOWN. The enrolment probe (`internal/hostprobe` `Network`) records the default-route NIC by MAC with no notion of link type, the spec gate (`internal/join/gate.go`: spec-gate / virt-unavailable / arch-unsupported) never looks at it, and the P2-S3 menu offered **Full install** as "Most reliable". The takeover then: 1. kexecs into the installer image, which has no wpa_supplicant and no credentials → no link → never rejoins the mesh → `target_lost`; 2. would, had it installed, bake a **MAC-matched systemd-networkd** static config (`renderNetworkd`, `enrollment.go:642`) for the WiFi NIC's MAC — a wireless interface networkd cannot bring up → an offline NixOS box. So a WiFi-only host can never complete a full install, and the product let the device owner consent to wiping it anyway. The fault is silent on the gateway (just a lost target) and silent on the device (no screen, no network). ## Fix (proposed — two-way door, ADR 0174) 1. **Probe the link type.** `NetworkFacts` gains `Wireless bool` (from `/sys/class/net/<iface>/wireless` or `iw dev`) for the default-route NIC, plus the list of wired NICs with carrier. Read-only, honest-empty when unreadable (ADR 0100). 2. **Gate it at consent.** On P2-S3, a host whose default route is wireless and that has NO wired NIC with carrier is **refused Full install** with a typed rejection (`RejectWirelessOnly`): headline "This machine is on Wi-Fi only", Need = "a wired network connection the installer and the installed system can use without credentials", Got = "Wi-Fi (<iface>) · wired port <eno1> has no cable", Remedy = "plug in an Ethernet cable and choose Full install again, or choose VM mode" — code survives. VM mode stays offered (the guest rides the host's networking). Same rule in the app doorway (app.go) and the terminal (cli.go). 3. **Belt at deploy.** `Deploy`/takeover refuses to start a takeover for a device whose recorded network facts are wireless-only (facts can change between consent and Set up — re-probe is the agent's; the control plane checks the last facts it holds) with the same words, before kexec — never a lost target. 4. **Honest failure copy.** When a kexec phase loses the target and no installer peer registers within the window, the failure's detail says so: "the installer never reached the network — check the machine has a wired link; power-cycling boots the previous OS, no disk work ran" instead of the bare ssh timeout dump. 5. Seam tests: wireless-only probe → full install refused, VM offered; wired-with-carrier → unchanged; takeover refused pre-kexec on wireless facts. ## Recovery on the demo (needs hands at the office) Power-cycle Delilah → it boots the untouched Ubuntu 26.04 (netbird reconnects to the community mesh, `idss-agent.service` returns). Plug in Ethernet to `eno1` before any further Set up. The fleet row node-req-0006 is still enrolled; the failed run's recovery mode is `rescue`. ## Related #2038, #2039, #2040 (same device, same day), #1013, #1068, ADR 0024, ADR 0209, ADR 0100, `internal/hostprobe/prober.go`, `internal/join/gate.go`, `internal/join/cli.go`, `internal/provision/takeover.go`, `internal/clan/enrollment.go` (`renderNetworkd`). GOTCHAS #392.

swarm-claim host=matou-dev-server-01 run=38663
(automated multi-host claim — lowest live claim id works this ticket)

swarm-claim host=matou-dev-server-01 run=38663 (automated multi-host claim — lowest live claim id works this ticket)

close-report for #2041 — status success

✅ close-report gates passed — every claim verified against main; issue closed.

envelope
{
  "issue": 2041,
  "status": "success",
  "commits": [
    "9a382df2116a3863cd12b764cbd574ce46902426"
  ],
  "changed_files": [
    "STATUS.md",
    "internal/clan/enrollment.go",
    "internal/clan/installer_repoint_test.go",
    "internal/enroll/enroll.go",
    "internal/enroll/networkfacts.go",
    "internal/hostprobe/prober.go",
    "internal/hostprobe/prober_test.go",
    "internal/hostprobe/sources_linux.go",
    "internal/join/app.go",
    "internal/join/app_test.go",
    "internal/join/cli_test.go",
    "internal/join/gate.go",
    "internal/provision/assess.go",
    "internal/provision/deploy.go",
    "internal/provision/takeover_test.go"
  ],
  "tests": [
    {
      "command": "go test ./internal/enroll/ ./internal/hostprobe/ ./internal/join/ ./internal/provision/ ./internal/clan/ ./internal/fleetstate/",
      "exit_code": 0
    },
    {
      "command": "go build ./... && go vet ./internal/enroll/ ./internal/hostprobe/ ./internal/join/ ./internal/provision/",
      "exit_code": 0
    }
  ],
  "criteria": {
    "Probe the link type: NetworkFacts gains Wireless + wired NICs, read-only honest-empty": "internal/enroll/enroll.go (Interface/Wireless/WiredCarrier/WiredNoCarrier) + internal/enroll/networkfacts.go (WirelessOnly); internal/hostprobe/sources_linux.go reads /sys/class/net; TestNetwork_ReportsWirelessOnlyHost / _WiredHostIsNotWirelessOnly",
    "Gate at consent: wireless-only refused Full install with RejectWirelessOnly, VM offered, code survives, same rule app + terminal": "internal/join/app.go Consent + internal/join/gate.go RejectWirelessOnly/WirelessOnlyError; TestConsent_WirelessOnlyRefusesFullInstall (app doorway) + TestTerminal_WirelessOnlyFullRefusedVMStaysOffered (terminal)",
    "Belt at deploy: takeover refused pre-kexec for wireless-only recorded facts, same words": "internal/provision/assess.go refuseWirelessOnlyTakeover + ErrWirelessOnlyTakeover, wired into deploy.go Deploy; TestDeployTakeover_RefusesWirelessOnlyBeforeKexec (no enroll/advance) + _WiredCarrierFullInstallUnchanged",
    "Honest failure copy: kexec target_lost with no installer peer names the wired-link check": "internal/clan/enrollment.go repointToRejoinedInstaller remedy; #2041 assertion in TestEnroll_KexecInstallerNeverRejoins_RedsTargetLost",
    "Seam tests: wireless-only -> full refused VM offered; wired-with-carrier unchanged; takeover refused pre-kexec": "the four test files above, all green"
  },
  "summary": "A Wi-Fi-only host is refused Full install at consent and before kexec, and a kexec that never rejoins the mesh fails with an honest wired-link remedy instead of being wiped into a lost target.",
  "unproven_by_seam": "The /sys/class/net link-type reads (hostprobe sources_linux.go) are exercised on real hardware by the WKT-DEMO device-add drive, not by these seam tests, which inject the Wireless/WiredNICs sources through hostprobe.NewWithSources.",
  "blockers": []
}
**close-report** for #2041 — status `success` :white_check_mark: **close-report gates passed** — every claim verified against main; issue closed. <details><summary>envelope</summary> ```json { "issue": 2041, "status": "success", "commits": [ "9a382df2116a3863cd12b764cbd574ce46902426" ], "changed_files": [ "STATUS.md", "internal/clan/enrollment.go", "internal/clan/installer_repoint_test.go", "internal/enroll/enroll.go", "internal/enroll/networkfacts.go", "internal/hostprobe/prober.go", "internal/hostprobe/prober_test.go", "internal/hostprobe/sources_linux.go", "internal/join/app.go", "internal/join/app_test.go", "internal/join/cli_test.go", "internal/join/gate.go", "internal/provision/assess.go", "internal/provision/deploy.go", "internal/provision/takeover_test.go" ], "tests": [ { "command": "go test ./internal/enroll/ ./internal/hostprobe/ ./internal/join/ ./internal/provision/ ./internal/clan/ ./internal/fleetstate/", "exit_code": 0 }, { "command": "go build ./... && go vet ./internal/enroll/ ./internal/hostprobe/ ./internal/join/ ./internal/provision/", "exit_code": 0 } ], "criteria": { "Probe the link type: NetworkFacts gains Wireless + wired NICs, read-only honest-empty": "internal/enroll/enroll.go (Interface/Wireless/WiredCarrier/WiredNoCarrier) + internal/enroll/networkfacts.go (WirelessOnly); internal/hostprobe/sources_linux.go reads /sys/class/net; TestNetwork_ReportsWirelessOnlyHost / _WiredHostIsNotWirelessOnly", "Gate at consent: wireless-only refused Full install with RejectWirelessOnly, VM offered, code survives, same rule app + terminal": "internal/join/app.go Consent + internal/join/gate.go RejectWirelessOnly/WirelessOnlyError; TestConsent_WirelessOnlyRefusesFullInstall (app doorway) + TestTerminal_WirelessOnlyFullRefusedVMStaysOffered (terminal)", "Belt at deploy: takeover refused pre-kexec for wireless-only recorded facts, same words": "internal/provision/assess.go refuseWirelessOnlyTakeover + ErrWirelessOnlyTakeover, wired into deploy.go Deploy; TestDeployTakeover_RefusesWirelessOnlyBeforeKexec (no enroll/advance) + _WiredCarrierFullInstallUnchanged", "Honest failure copy: kexec target_lost with no installer peer names the wired-link check": "internal/clan/enrollment.go repointToRejoinedInstaller remedy; #2041 assertion in TestEnroll_KexecInstallerNeverRejoins_RedsTargetLost", "Seam tests: wireless-only -> full refused VM offered; wired-with-carrier unchanged; takeover refused pre-kexec": "the four test files above, all green" }, "summary": "A Wi-Fi-only host is refused Full install at consent and before kexec, and a kexec that never rejoins the mesh fails with an honest wired-link remedy instead of being wiped into a lost target.", "unproven_by_seam": "The /sys/class/net link-type reads (hostprobe sources_linux.go) are exercised on real hardware by the WKT-DEMO device-add drive, not by these seam tests, which inject the Wireless/WiredNICs sources through hostprobe.NewWithSources.", "blockers": [] } ``` </details>
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Matou/idss#2041
No description provided.