Use this when SMART shows reallocated sectors.
Reallocated Sectors
Reallocated sectors (SMART 5) are bad sectors the drive has replaced with spare ones. A few may be stable, but a rising count means the surface is degrading and the drive should be replaced.
1. Reallocated sectors = bad sectors remapped to spares.
2. A few may be OK; increasing counts = replace.
3. In arrays, replace proactively.
4. Run long test.
5. Track trend.
bad sector → remapped → counter
Context & applicabilityCommon mistakes · platform/version boundaries
Operational reference
Fast context before you go deeper.
Verification & Troubleshooting
Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.
Use the operational verification above to establish the expected state.
Capture the concrete output, symptom, packet, log or counter before changing anything.
Step 1 Common mistakes Narrow the fault
- Keeping a drive whose count rises weekly.
Evidence · 1 on this Topic
Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.
- Bad sectors replaced with spares.
- Stable small counts may be tolerable.
- Rising counts mean replace.
smartctl -A /dev/sdX | grep -i reallocated— ID 5smartctl -a /dev/sdX | grep -i 'grown defect'— SAS equivalenthistory of values— trend
ReferenceHow it works1 section · depth on demand
Commands
smartctl -A /dev/sda | grep -i realloc
Record the value weekly; replace on steady growth.
ReferenceImportant terms & boundaries3 sections · depth on demand
In depth
Reallocated sectors: the drive has already replaced bad blocks
When a sector fails, the drive maps it to a spare area. Attribute 5 (Reallocated_Sector_Ct) counts those remaps. Reads and writes keep working, but the media is degrading.
# smartctl -A /dev/sdb | grep -E '^ *(5|196|197|198) '
5 Reallocated_Sector_Ct 0x0033 098 098 010 Pre-fail Always - 184
196 Reallocated_Event_Count 0x0032 098 098 000 Old_age Always - 184
197 Current_Pending_Sector 0x0012 100 100 000 Old_age Always - 8
198 Offline_Uncorrectable 0x0010 100 100 000 Old_age Offline - 8
smartd.conf(5) documents -R ID[!] to report changes in an attribute's raw value, with ! marking the change as critical. The manual's example -R 5! warns on reallocated sectors.
/dev/disk/by-id/ata-WDC_WD80-XYZ -a -R 5! -C 197+ -U 198+ -m root
Interpretation
| Raw count and trend | Action |
|---|---|
| 0 | Normal |
| Small, stable for months | Watch; plan replacement in redundant storage |
| Increasing week over week | Replace soon |
| Increasing with pending or uncorrectable sectors | Replace now; check backups |
| VALUE at or below THRESH | Drive predicts failure (-H will say FAILED) |
Why the raw value matters
Normalised values drop slowly and the threshold is often very low, so a drive can have hundreds of remapped sectors and still report PASSED. Alert on raw-value changes.
Before replacing
Run a long self-test (smartctl -t long) and a scrub or RAID check. The aim is to rewrite or repair any data in weak areas while redundancy still exists.
Documented example, not captured output.
Quick reference
A drive keeps a pool of spare sectors. When a sector fails to write or read reliably, its address is remapped to a spare and attribute 5 increases. Large studies (e.g. Backblaze) have found drives with any reallocated sectors fail far more often than those without; a rising count is a replacement signal, especially in RAID where a second failure during rebuild is the risk.
smartctl -A /dev/sda | grep -i reallocated
smartctl -t long /dev/sda ; smartctl -l selftest /dev/sda
Reference
Each reallocated sector was replaced by a spare. A few may be stable for years; a growing count means the drive is failing. Replace if it keeps rising or exceeds vendor guidance.
Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Verification history & basis
When and against what this Topic was checked. Later text edits do not count as a new check.
Authoritative/upstream documentation reviewed for bounded claims in SMART & Disk Health → Reallocated Sectors. Documentation verification only; this is not observed lab or production Evidence.
Basis: https://www.smartmontools.org/ · confidence 94%