User Tools

Site Tools


zfs:structure:vdev

ZFS - Structure - vdev

Each zpool consists of one or more vdevs (virtual devices).

  • Each vdev, in turn, consists of one or more real devices.
  • Most vdevs are used for plain storage, but several special support classes of vdev exist:
    • CACHE
    • LOG
    • SPECIAL
  • Each of these vdev types can offer one of five topologies
    • Single-device.
    • Mirror.
    • RAIDz1.
    • RAIDz2.
    • RAIDz3.

RAIDz1, RAIDz2, and RAIDz3 are special varieties of what storage greybeards call “diagonal parity RAID.”

  • The 1, 2, and 3 refer to how many parity blocks are allocated to each data stripe.
    • Rather than having entire disks dedicated to parity, RAIDz vdevs distribute that parity semi-evenly across the disks.
  • A RAIDz array can lose as many disks as it has parity blocks; if it loses another, it fails, and takes the zpool down with it.

Mirror vdevs mirror each block on every device in the vdev.

  • Although two-wide mirrors are the most common, a mirror vdev can contain any arbitrary number of devices—three-way are common in larger setups for the higher read performance and fault resistance.
  • A mirror vdev can survive any failure, so long as at least one device in the vdev remains healthy.

Single-device vdevs are inherently dangerous.

  • A single-device vdev cannot survive any failure.
  • If it is being used as a storage or SPECIAL vdev, its failure will take the entire zpool down with it.
  • Be very, very careful here!!!

CACHE, LOG, and SPECIAL vdevs can be created using any of the above topologies.

  • But remember, loss of a SPECIAL vdev means loss of the pool, so redundant topology is strongly encouraged.
zfs/structure/vdev.txt · Last modified: 2021/10/13 01:25 by peter

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki