r/zfs•
FrakenTurtle

Setting Increased Parity

OS is FreeBSD Latest and I need to get a handle on ZFS Parity files as we're looking at 3-5 copies for faster resliver/recovery from a disk failure. Yes we've looked at DRAID and it's interesting but now the direction we want as Robustness is critical so any links for reading are acceptable.

Posted May 6, 2022, 8:22 PM UTC

18
zfsbest•

Not sure what you mean by ZFS Parity "files" - you can have triple mirrors and up to RAIDZ3, both of which can sustain up to (3) simultaneous disk failures per-vdev with no data loss... RAIDZ2 starts to make sense at around the 6-disk mark so I imagine RAIDZ3 would make sense around 7+ which would give you 4 for data and 3 for parity. Expand the vdev as needed but don't go too wide, there are recommended limits out there.

Just tested with a file based pool and you can do quadruple mirrors at the cost of extra disk space vs redundancy

Further reading:

https://www.reddit.com/r/zfs/comments/bd5d45/why_seasoned_zfs_admins_suggest_not_to_have_too/

https://www.truenas.com/community/threads/is-there-still-an-optimal-number-of-drives-for-each-raidz-configuration.97202/

https://static.ixsystems.co/uploads/2020/09/ZFS_Storage_Pool_Layout_White_Paper_2020_WEB.pdf

2
FrakenTurtleOP•

Not sure if I'm using the right term so forgive this Noob:

Thanks for the links

Interesting on the Truenas discussion. What we're looking at is a max of 6 disks in the pool with a hot spare, so it looks as though raidz is what we need to keep disk rebuild times down and lessen the risk of loosing a second drive during the rebuild.

Not sure if RaidZ-2 is what we want as we're only using 6 active and a single spare but the sub-thread about the diff indicates the safety of z2 may be what we want

2
zfsbest•

Test on your own hardware, but ZFS resilvers typically take much less time because they only resilver based on "data used" not the entire drive. So if your pool is ~50% used it should only need to resilver ~50% of the drive, but this varies based on allocation among the different pool disks

2
FrakenTurtleOP•

Thanks for that info as I wasn't aware that ZFS was Smart and only needs to rebuild based on actual usage.

3
FrakenTurtleOP•

Interesting Comment about the difference between RaidZ and Raid

Also remember that a RAIDZ is not RAID3/4/5. It does not have a
dedicated checksum disk, nor a fixed checksum striping pattern. ZFS
puts the data block and the checksum block wherever it feels like
putting it. So a 5x RAIDZ on sequential reads will get 5 spindles worth
of read, and 4 spindles worth of write. In a 4x RAID10, you get 4
spindles worth of read, and 2 spindles worth of write. Even a 4x RAIDZ
comes out ahead, with 4 spindles worth of read, and 3 spindles worth of
write.

1
fryfrog•

You should figure out a fio that represents your read/write work load and do some tests. ZFS does things differently from many traditional raid, but that doesn't mean its always faster (or slower). And in general, a pool of mirrors (~raid10) will be more performant than anything else.

1
fryfrog•

Unless you have multiple vdevs, using raidz + hot spare is a poor idea compared to just using raidz2 from the start.

1
Klara_Allan•

I agree here. If you only have 1 vdev, might as well make the spare part of the pool and get the additional parity and performance.

1