What smartctl and smartd can and cannot tell you about a failing drive
Published 2026-10-11 · Updated 2026-10-15
A successful smartctl process is not a complete health measurement. ATA exit bits distinguish command problems, threshold warnings and logged errors; PASSED is a reported check result, not a guarantee against failure. This guide separates those signals, explains smartd alert prerequisites and preserves unknown readings in tested collector examples.
On this page9 sections
- Question
- Which result was actually measured, which commands failed or were skipped, and which alert path was configured?
- Evidence
- Pinned smartmontools 7.5 source and manuals; historical Backblaze operator data and the FAST 2007 field study.
- Example boundary
- Synthetic ATA JSON cases and exhaustive bitmask arithmetic tests, not real drive observations or a predictor.
- Reviewed
- Tool semantics and FAST 2007 checked on 2026-10-15; historical Backblaze figures retained from the 2026-10-11 review.
What each smartctl check reads and what it can say
smartmontools 7.5 documentation, reviewed 2026-10-15. Attribute scores are firmware-defined; they are not universal health percentages.
| Check | What it reads | What the manual says a bad result means | What it does not say | Source |
|---|---|---|---|---|
| -H (ATA) | The boolean result of the SMART RETURN STATUS command | The drive has already failed, or predicts its own failure within the next 24 hours | PASSED can also come from an attribute-based fallback when the status command is unavailable; retain warnings and command status, not just the printed word | smartctl(8) manual |
| -H (NVMe) | The Critical Warning byte of the SMART/Health Information log | A warning bit is set | Health beyond that one byte; the manual gives no list of bits in this section | smartctl(8) manual |
| -H (SCSI) | Additional Sense Code and Qualifier from the Informational Exceptions log page or from sense data | The device reports a failure prediction through that code | Anything the device does not put in that log page | smartctl(8) manual |
| -A attribute table | Per-attribute raw value, normalized value (1 to 254), worst value, threshold (0 to 255) and type, as stored on the device | If normalized is at or below the threshold the attribute has failed; for a pre-failure attribute, failure is imminent; WHEN_FAILED shows FAILING_NOW or In_the_past | Being of type Pre-fail does not mean the disk is about to fail; smartctl does not calculate values, thresholds or types, and the raw-to-physical-unit conversion is not specified by the SMART standard | smartctl(8) manual |
| Old-age (usage) attribute at threshold | The same table, attributes of type Old_age | An advisory that the device has exceeded its intended design life | Not imminent failure; smartd's -f directive reports these and the smartd page says the same | smartd.conf(5) manual |
| -t short / -t long self-test (ATA) | Electrical, mechanical and read performance of the disk, logged in the self-test log | A logged failure in the self-test log (read with -l selftest) | Short is usually under 10 minutes, long takes tens of minutes to several hours; the manual does not state a detection rate for either | smartctl(8) manual |
smartctl exit status: eight separate signals in one number
ATA meanings under the normal smartctl 7.5 exit-bitmask policy. Bits can coexist: decimal 12 means bits 2 and 3. Custom -n exit values are a separate policy; zero can mean a deliberately skipped check.
| Bit | Decimal value | Meaning in the manual | Kind of signal | Source |
|---|---|---|---|---|
| 0 | 1 | Command line did not parse | Tool usage error, not a drive state | smartctl(8) manual |
| 1 | 2 | Device open failed, no IDENTIFY DEVICE structure returned, or device in a low-power mode | Access/identification failure or intentional low-power skip; the code alone does not distinguish them | smartctl(8) manual |
| 2 | 4 | A SMART or other ATA command failed, or a SMART data structure had a checksum error | Could not read the data (includes unknown status through a bridge) | smartctl(8) manual |
| 3 | 8 | SMART status check returned DISK FAILING | Failing health result, potentially from the documented attribute fallback | smartctl(8) manual |
| 4 | 16 | Pre-fail attributes found at or below threshold | Attribute failing now | smartctl(8) manual |
| 5 | 32 | Status check returned DISK OK but some attributes have been at or below threshold in the past | History flag | smartctl(8) manual |
| 6 | 64 | The device error log contains records of errors | Error log, not a threshold | smartctl(8) manual |
| 7 | 128 | The self-test log contains records of errors (failed tests superseded by a newer successful extended test are ignored) | Self-test result | smartctl(8) manual |
What smartd watches by default and how often
smartmontools 7.5 configuration documentation, reviewed 2026-10-15. Polling, self-test scheduling and e-mail delivery are separate mechanisms.
| Setting | Value | What it means for monitoring | Source |
|---|---|---|---|
| Polling interval | 1,800 s default (30 minutes); minimum allowed 10 s | Nominally 48 polling intervals per 24 hours (86,400 / 1,800); this is not 48 guaranteed successful observations or an alert-delivery guarantee | smartd.conf(5) manual |
| Directive -a (the default if none is given) | -H -f -t -l error -l selftest -l selfteststs, and for ATA also -C 197 -U 198 | Enables checks and tracking, not e-mail delivery or a self-test schedule; configure -m for notifications and -s REGEXP for scheduled tests | smartd.conf(5) manual |
| Pending sector check (-C) | Reports any non-zero count in attribute 197 (default ID); with '+' only when the count has increased between two checks | Signals unreadable data under the device's attribute convention. Forcing a rewrite is not data recovery; preserve readable data before remedial writes | smartd.conf(5) manual |
| Warning e-mail reminders | once, daily, diminishing (and the 7.4 experimental always mode) | Requires -m. Default is once without state persistence and daily with it; diminishing is optional, not the default. Test the notification route separately | smartd.conf(5) manual |
| Scheduled self-test example | -s (O/../.././(00|06|12|18)|S/../.././01|L/../../6/03) | The manual's own example: offline test every 6 hours, short test at 01:00 daily, long test Saturdays at 03:00; tests run after a polling cycle, so a polling interval above 60 minutes can miss the slot | smartd.conf(5) manual |
How many failed drives raised each flag, compared with working drives
Backblaze: percent of drives with a raw value above zero, failed drives measured one day before failure (MSST 2017 slide, 'Behind the Curtain of Backblaze Hard Drive Stats'); ratio is derived (failed % / working %). The group figures come from the 6 October 2016 blog post (67,814 drives). Google: percent of failed drives, FAST 2007, with its own definition of failure (drive replaced during a repair).
| Measure | Failed drives (%) | Working drives (%) | Ratio failed / working (times, derived) | Source |
|---|---|---|---|---|
| SMART 5, Reallocated Sectors Count | 42.2 | 1.1 | 38.4 | Backblaze MSST 2017 slides |
| SMART 187, Reported Uncorrectable Errors (Seagate only) | 43.5 | 0.5 | 87.0 | Backblaze MSST 2017 slides |
| SMART 188, Command Timeout (Seagate only) | 44.8 | 4.8 | 9.3 | Backblaze MSST 2017 slides |
| SMART 197, Current Pending Sector Count | 43.1 | 0.7 | 61.6 | Backblaze MSST 2017 slides |
| SMART 198, Uncorrectable Sector Count (Seagate only) | 33.0 | 0.3 | 110.0 | Backblaze MSST 2017 slides |
| Any one or more of those five above zero (blog post, 2016) | 76.7 | 4.2 | 18.3 | Backblaze, 6 Oct 2016 |
| SMART 189, High Fly Writes (candidate stat, 2016) | 47.0 | 16.4 | 2.9 | Backblaze, 6 Oct 2016 |
| Google: failed drives with no count in any of four strong signals (scan errors, reallocations, offline reallocations, probational count) | over 56 | not stated | not stated | Pinheiro et al., FAST 2007 |
| Google: failed drives with zero counts on all SMART variables except temperature | over 36 | not stated | not stated | Pinheiro et al., FAST 2007 |
Collector examples: preserve unknown and combined results
A collector should capture stdout, stderr and the process status separately, then check that valid JSON contains the same smartctl.exit_status. A successful JSON parser does not establish a successful device query. The program writes its result into JSON before exiting; launcher errors and truncated output need separate handling.
The ATA implementation can set smart_status.passed after falling back to attribute thresholds. Preserve that value as a reported result, not proof that the status command succeeded. An absent value stays unknown; a boolean pass must not erase collection-error bits.
Under custom low-power policy, -n standby,0 may return zero without a health check. Our example refuses to decode exit bits unless the caller explicitly confirms the normal policy. It accepts ATA only and is not an alarm policy or a failure predictor.
Synthetic examples, not measurements. Results below are computed by the downloadable decoder at build time. Bit numbers start at zero.
| Input case | Exit / set bits | Reported health | Interpretation |
|---|---|---|---|
| No health field | 0 / none | unknown | Zero bits, but no health observation. |
| Reported pass | 0 / none | passed | A reported pass, not predicted survival. |
| Pass plus error log | 64 / 6 | passed | Bit 6 coexists with a passed health result. |
| Command problem plus failure | 12 / 2, 3 | failed | Bits 2 and 3 are both preserved. |
| Pass with command problem | 4 / 2 | passed | Do not discard command failure or fallback warnings. |
| Custom low-power zero | 0 / not decoded | not decoded | Custom -n standby,0 policy: bitmask interpretation refused. |
Reproduce with the pure JavaScript decoder, synthetic JSON inputs and method and invocation notes. Definition: smartctl exit status.
Interpreting observations and field studies
Keep three observations separate: the smartctl process result, the reported health check and the specific attributes or logs collected. A nonzero process result can coexist with useful JSON; a missing health boolean cannot be converted to PASSED. Even a reported pass can be an attribute-based fallback rather than a successful SMART RETURN STATUS command.
Sources: smartctl(8) manual; ATA health implementation.
The field-study denominators matter. Pinheiro, Weber and Barroso examined more than 100,000 consumer ATA drives over December 2005 to August 2006. In section 3.5.6, over 56% of failed drives had zero counts in the four strongest signals; over 36% had zero counts across the SMART variables considered other than temperature. These are different signal sets in the same historical population, not two estimates of current smartctl detection accuracy. They do not measure useful alert lead time.
Sources: Pinheiro et al., FAST 2007.
The Backblaze columns condition on failed versus working drives: they estimate flag prevalence within those groups. A large ratio between those percentages is not the probability that a flagged drive will fail. Turning it into a forecast requires a defined prediction horizon, population base rate and prospective evaluation; rounded percentages alone do not supply uncertainty bounds.
Sources: Backblaze, 6 Oct 2016; Backblaze MSST 2017 slides.
DEVICESCAN selects devices; it does not configure a mail recipient. The default -a group enables checks, while -m supplies the notification destination and -s REGEXP schedules self-tests. Reminder policy is separate: diminishing is optional. A running daemon, a successful poll, a completed self-test and a delivered alert are four different observations to verify.
Sources: smartd.conf(5) manual.
Treat warnings as reasons to preserve evidence and investigate the device plus its access path, not as a universal component diagnosis. Retain tool version, command arguments, device identity, timestamps and warning messages. Do not overwrite a suspect sector merely to make its pending counter disappear.
Sources: smartctl(8) manual; smartd.conf(5) manual.
Related: the SMART failure-signal note, NVMe health log coverage and USB bridge and UAS failure signatures.
Method
This is a documentation and source-code review, not a drive experiment. The 2026-10-15 revision checked smartmontools 7.5 at commit f276b249fdc84019403491303479485030ac7c80: smartctl(8), smartd.conf(5), smartctl.cpp and ataprint.cpp. The FAST 2007 full paper was reread, especially sections 2 and 3.5.6. The earlier Backblaze table is retained from the 2016 post and MSST 2017 slide deck reviewed on 2026-10-11. Its ratios divide the displayed failed-drive flag prevalence by working-drive flag prevalence, rounded to one decimal. They are not prospective failure-risk ratios. The new examples are synthetic JSON observations evaluated by the published JavaScript module; the test suite enumerates all 256 possible eight-bit masks and checks invalid inputs, missing health fields, status mismatches and custom-exit refusal. No device is opened by that module.
Limits
No smartctl or smartd command was executed against hardware, and no alert-delivery rate was measured. The example accepts only ATA reports with a known normal bitmask policy; SCSI and NVMe need their own interpretation. It retains the reported boolean without claiming that it came directly from SMART RETURN STATUS: the ATA code can derive it from attributes after an unavailable status command. Keep the complete invocation, version, warnings, timestamps and device identity when investigating. A missing field is unknown, not healthy. Custom -n exit values and launcher or privilege-helper failures must not be interpreted as ordinary smartctl bits. Backblaze and Google describe different historical HDD populations and failure definitions, not modern SSD/NVMe coverage. The Backblaze slide does not provide the subgroup counts needed for confidence intervals; do not manufacture them from rounded percentages. Vendor-specific attribute availability and a useful warning lead time must be established separately.
Sources
- 01smartmontools 7.5: smartctl(8), pinned source · accessed 2026-10-15
- 02smartmontools 7.5: smartd.conf(5), pinned source · accessed 2026-10-15
- 03Backblaze: What SMART Stats Tell Us About Hard Drives, 6 October 2016 · accessed 2026-10-11
- 04Klein (Backblaze): Behind the Curtain of Backblaze Hard Drive Stats, MSST 2017 slides · accessed 2026-10-11
- 05Pinheiro, Weber, Barroso: Failure Trends in a Large Disk Drive Population, FAST 2007 · accessed 2026-10-15
- 06smartmontools 7.5: ATA health result and attribute fallback implementation · accessed 2026-10-15
- 07smartmontools 7.5: JSON exit_status and process exit implementation · accessed 2026-10-15