Pcornel
Storage

ZFS

Cheat sheet · https://pcornel.dk/topic.php?topic=394

Back to the Topic

Answer

ZFS organizes leaf devices into vdevs, combines top-level vdevs into a zpool, and allocates checksummed copy-on-write blocks to datasets or zvols. Pool redundancy is determined by each top-level data vdev, while dataset properties control logical behavior above the pool. End-to-end health requires proving pool topology, vdev/device health, dataset state, capacity, integrity and workload behavior separately.

Remember

  • ZFS pool ≠ filesystem dataset.
  • Top-level vdev redundancy determines the pool failure boundary; adding capacity does not automatically widen existing redundancy.
  • Snapshot ≠ independent backup.
  • Checksums detect corruption, but repair requires another valid copy of the affected block.

First checks

  • zpool status -x — pool health
  • zpool list — capacity/fragmentation
  • zfs list -o name,used,avail,compressratio — datasets

Commands

sudo zfs list
ZFS datasets/zvols and usage.
zpool status
Local state
zpool status -v
zpool events
zfs list

Verify in this order

datasets/zvols → pool → vdevs → disks

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 ZFS map

ZFS boundaryWhat to verifyProof limit
Identity / topologyPool GUID/name, dataset/zvol, top-level vdev class, leaf-device identity and effective propertiesObject presence alone does not prove integrity, performance or recovery
Capacity / protectionPool free space, quotas/reservations, snapshot retention, redundancy and active scrub/resilver stateFree space or ONLINE state at one layer does not prove end-to-end health
Failure boundaryA pool reported ONLINE proves the currently imported topology satisfies ZFS availability rules; it does not prove every block has been read recently, application consistency, performance headroom, or recoverable backups.Correlate ZFS evidence with both workload and lower device/path evidence
AcceptanceHealthy evidence: expected pool imports with the intended top-level vdev layout, all required devices are present, no persistent checksum/read/write errors are accumulating, capacity headroom is known, and representative reads/writes succeed.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=394

Confirmation

Confirm action

Continue?