ADR 0256: say exactly how a SAS drive, a USB drive and a stuck read are treated
mesh/merge-gate pass: the change touches no module of the mesh's graph
mesh/repo-check pass: its merge-check.sh passed
mesh/delivery delivered

The SAS sentence now holds for modes with spaces, a hung read is unhealthy in two to three minutes, not
one, every USB drive is told sat, and the limits of a stuck read are recorded.
This commit is contained in:
jochen
2026-10-08 15:04:03 +02:00
parent 0406373545
commit df41dfff38
@@ -168,12 +168,16 @@ as not read, never as cool. Nothing here conflicts with GENESIS.
- The module installs a package (`smartmontools`) for `smartctl`, and runs two processes of its own as
root, each writing one file under the runtime directory and nothing else. It does not run `smartd`.
- **A drive is not woken by the module, as far as the drive can say so.** Each read is asked with
`-n standby`, and smartctl stops without reading when the drive says it is in standby or asleep (an ATA
drive by its power mode, a SAS drive or one the operating system powered down by smartctl's own words).
smartctl is told the drive's kind (`-d nvme`, `sat` or `scsi`) where it is known, so it does not probe a
drive to find out. A drive that cannot say whether it is asleep (a USB bridge that does not pass the
question on) is not read at all, and is said as not read. What remains: a drive of a kind the module
cannot tell is read with smartctl's own detection.
`-n standby`, and smartctl stops without reading when the drive says it is in standby or asleep. An ATA
drive says it by its power mode (STANDBY, STANDBY_Y, SLEEP). A SAS drive, or one the operating system
powered down, says it in smartctl's own words, "Device is in <mode> mode, exit(2)", where a SAS mode
holds spaces (STANDBY BY TIMER, STANDBY_Y BY COMMAND, LOW POWER); the module takes every such mode, and
an idle mode never stops smartctl. smartctl is told the drive's kind (`-d nvme`, `sat` or `scsi`) where
it is known, so it does not probe a drive to find out. A drive behind USB is always told `sat`: one
behind a USB-to-NVMe enclosure or a vendor's own bridge does not answer to it, and is said as not read.
A drive that cannot say whether it is asleep (a USB bridge that does not pass the question on) is not
read at all, and is said as not read. What remains: a drive of a kind the module cannot tell (a virtual
disk, a memory card) is read with smartctl's own detection.
- **Reading a drive may keep it from spinning down.** Reading SMART from an awake drive can restart its
standby timer, so a drive read more often than its timer is set for never reaches standby. Whether the
servers' drives are set to spin down is not known: no mesh tool reads a drive's standby timer or power
@@ -184,7 +188,12 @@ as not read, never as cool. Nothing here conflicts with GENESIS.
longer than an hour can still be kept awake. Reading the power mode and the timer is a follow-up for
this module's tools.
- **A drive that stops answering may look asleep**, and is then HIGH after a day, never unhealthy (rule
4). A drive whose read hangs instead is unhealthy within a minute of its bound.
4). A drive whose read hangs instead is unhealthy in about two to three minutes: its read is said once
it is past its 52 s bound, and the health check needs two looks 60 s apart to be unhealthy.
- **Known limits of a stuck read.** A smartctl stuck in the kernel cannot be ended, and outlives the
drive reader: a restarted reader starts a new read of that drive, which may stick beside the first. The
reads of all drives run at once, with no cap per controller or bridge; a server with many drives on one
controller asks it all at once, once an hour.
## Follow-ups