I'm planning on building a fileserver on top of opensolaris, using either a raid z1 or z2. Is it possible to later upgrade a disk at a time and immediately have access to the increased storage? Or is the increased storage only available when every device in the raid z upgraded?

Also, how do regular zpools treat devices of different sizes? I've found no certain answers about this. I may have to start out with two drives of different sizes in a zpool without any redundancy at first. I've heard from some that each drive is treated as the size of the smallest disk (both in zpools and raid zs), but the zfs documentation seems to imply otherwise.


I just had to test this out in VirtualBox. It turns out you're limited by the size of the smallest disk in the pool. Thus 2x500GB and 1x250GB in raidz1 will yield only 250GB of usable space. Once you upgrade the last disk (and ensure zpool set autoexpand=on thepool) then you gain access to the extra space.

Regular zpools stripe the data across as many disks/vdevs you have in your pool and if one is larger than the other, it just stops striping when the smaller disk is full.


Instead of upgrading raidz disks which won't help increasing a pool size until all disks are upgraded, you can increase the size of a pool by adding a whole new raidz to it.

About your second question, if you are not using redundancy in a pool and use disks of different size, the global available size will be the sum of each disk size and not limited by the smallest one. If you use redundancy (mirroring or raidz), the smallest disk size will rule.


Technically, you can do a RAIDZ setup that would permit you to upgrade disks one at a time and have the added space available. But this requires a setup with partitions on all the drives and also requires creating partitions on the new drive before being able to use it. It's not straightforward although not that difficult. It just requires a bit of planning and good understanding on the way ZFS and RAIDZ works.

This is demonstrated in an example at http://www.cod3r.com/2010/04/zfs-on-different-sized-disks/

If you want to have an easy upgrade path and have spare disk controllers, using multiple mirrored pools might be easier, as explained at https://blogs.oracle.com/constantin/entry/opensolaris_home_server_zfs_and

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.