diff --git a/agent/BACKLOG.md b/agent/BACKLOG.md index ce30ad2..3712006 100644 --- a/agent/BACKLOG.md +++ b/agent/BACKLOG.md @@ -30,6 +30,48 @@ These are separate queue items from one real install/session pass. Preserve that separation when fixing them: the installer blocker, unclear installer copy, and post-install desktop failures have different verification paths. +### 118. smartd fails where no drive has SMART, so the health icon greets you red + +Bernardo, live ISO 2026-07-14: the Waybar doctor module shows a smartd error. + +**Root cause, reproduced headlessly 2026-07-14** (scratch `runNixOSTest`, a +node whose only config is `services.smartd.enable = true` — the same block +`modules/nixos/default.nix:166` mkDefaults ON for every machine): + + smartd[567]: In the system's table of devices NO devices found to scan + smartd[567]: Unable to monitor any SMART enabled devices. Exiting. + smartd.service: Main process exited, code=exited, status=17/n/a + Status: "No devices to monitor" + +`smartctl --scan` prints **nothing** on such a machine — which is both the +cause and the ready-made gate. The rest of the chain is each part working +correctly: `systemctl --failed` lists `smartd.service`, so nomarchy-doctor's +generic failed-unit check (`nomarchy-doctor.sh:24-28`) reports "failed system +unit(s): smartd.service", and Waybar's `#custom-doctor` goes `@bad`. **Fix +smartd, not the doctor** — the doctor is telling the truth about a unit that +genuinely failed. + +**Scope is wider than the live ISO** (which is why it's here and not filed as +a live-only nit): `services.smartd.enable` mkDefaults true on `nomarchy` as +well as `nomarchy-live`, and QEMU virtio disks expose no SMART — so a plain +VM install boots to a red health icon out of the box, as does a live USB whose +stick has no SMART. Every V2 QEMU run has been showing this. + +Fix direction: **self-gate on the hardware**, the convention the rest of the +distro follows (`ExecCondition`, like the night-light; "each half self-gates +on its hardware"). A condition that runs `smartctl --scan` and skips the unit +when it finds nothing leaves the unit *inactive* rather than *failed*, so real +SMART failures on real drives still surface. Do **not** paper over it with +`SuccessExitStatus = 17` — that also swallows the case where smartd dies on a +machine that does have drives, which is the whole reason the daemon is here. + +Pass = on a machine with no SMART-capable device the unit is inactive (not +failed), `systemctl --failed` is empty and the doctor is green; on a machine +with one, smartd runs as it does today; a permanent `checks.*` covers both +halves (the scratch repro above is most of it — the no-SMART node exists, the +with-SMART node needs a QEMU disk that answers SMART, or the gate script +tested directly against a stubbed `smartctl`). + ### 94. Live ISO/install: no default browser observed **Progress 2026-07-13:** installed path VERIFIED at V1 — the exact HM