This is a personal and professional blog of a Network Administrator's/Avid Gamer's knowledge and passions in Minneapolis.
I'm always looking to improve my skill set, and even more so I enjoy passing that knowledge along to others about my craft.
I always feel like IT limits what people do, so I aspire to enable technology, and explain complex things in simple terms.
More

ZFS RAID-Z partitioning efficiency

I’ve finally got around to setting up FreeNAS at home, and testing it out.

Overall so far, I’m very impressed. Tons of features. Where I’ve been a bit hung up is the mystical, magical ZFS.

I’ve been exploring just how it works, and I’ll try to explain it in simpler terms, and fail miserably.

Using ZFS, you create Virtual devices [Vdev] that are some sort of storage.

It could be a chunk of a hard drive, a whole hard drive, or even a hardware or software LUN, which is some volume recognized by the BIOS or RAID card configuration.

Further, for example, If I had 8 hard drives, I could use the first 10GB of each drive to make a RAID-Z2 (which is comparable to RAID6, 2 parity devices], which would give me 80GB total space, and 60GB usable, with 20 GB lost to parity.

Once you have your Virtual devices set up, you can combine them into a “Pools”. Pools are made up of one or more Vdevices. What those devices are [Single Disk, RAID-Z, RAID-Z2, etc] doesn’t matter.

So with the infinite number of configurations I can make, whats the most disk space I can get, while say, using RAID-Z2. That is, I can handle two drive failures without any data loss.

On my test rig at home, I have 9 disks as follows: 640GB, 500GB, 500GB, 500GB, 250GB, 250GB, 250GB, 120GB, 120GB.

To brain this, I ended up putting it down on an excel spreadsheet, with a different color for each drive.

1

And played around with the different things I could do.

234

Even while wasting 140GB on the biggest drive, none of them could beat

5

I’ve been throwing this one around a few days, but couldn’t quite wrap around it in my head. But after some nerding around, the answer rings true.

The most efficient way to use your different sized hard drives  for ZFS is to use as many disks as possible in each virtual device.

Leave a Reply

You must be logged in to post a comment.