Resilver
Cheat sheet · https://pcornel.dk/topic.php?topic=4034
Answer
Resilvering reconstructs blocks needed to restore redundancy for the affected device/vdev by reading valid data from surviving replicas/parity and writing the required blocks to the target. It is different from a scrub because its purpose is to synchronize redundancy after device state changes rather than verify every allocated copy across the entire pool.
Remember
- Resilver ≠ scrub.
- Resilver complete ≠ backup or application-integrity proof.
- Target device ONLINE before completion ≠ full redundancy restored.
- Resilver speed ≠ fixed device throughput; workload, topology, errors and allocation shape matter.
First checks
zpool status <pool>— resilver progresszpool replace <pool> <old> <new>— replace diskzpool get autoreplace <pool>— auto replace setting
Commands
zpool replace -s
Verify in this order
disk replaced → resilver → ONLINE
Where it usually breaks
First mismatch in member media → metadata/layout → allocation/placement → redundancy/recovery → logical object → consumer; preserve identity/pre-state before mutation.
ZFS → Resilver ZFS map
| ZFS boundary | What to verify | Proof limit |
|---|---|---|
| Identity / topology | Pool GUID/name, dataset/zvol, top-level vdev class, leaf-device identity and effective properties | Object presence alone does not prove integrity, performance or recovery |
| Capacity / protection | Pool free space, quotas/reservations, snapshot retention, redundancy and active scrub/resilver state | Free space or ONLINE state at one layer does not prove end-to-end health |
| Failure boundary | A completed resilver proves ZFS synchronized the required allocated block replicas for that event without remaining reported failure; it does not prove every block copy was scrubbed or the application is consistent. | Correlate ZFS evidence with both workload and lower device/path evidence |
| Acceptance | Healthy evidence: resilver completes, intended member is restored to the correct vdev, no persistent errors remain or grow, and representative workload plus subsequent integrity checks are clean. | Close only after original workload plus checksum/read-back/recovery verification succeeds |
Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=4034