Replacing one drive in a Raid-Z2 Vdev with a higher capacity one

Status
Not open for further replies.

Jon Smark

Dabbler
Joined
Aug 29, 2016
Messages
37
I'm new to FreeNAS, and I'm still researching before I actually attempt my first build. Anyway, I think I understand the relation between Zpools, Vdevs, and individual drives, but one doubt remains: suppose I have a Zpool consisting of a single Vdev, which in turn consists of 4 drives using Raid-Z2. Suppose also that initially all drives are 3TB drives. Since I cannot grow a Z2 Vdev by adding more drives, the only way the storage in this Vdev can grow is by increasing the capacity of each drive, right? But suppose I replace the drives one by one as each drive fails, and the replacements will be 4TB drives. Does the capacity of the pool only actually increase when the last 3TB drive is replaced by a 4TB one? Or is Raid-Z2 smarter than this and can already start taking advantage of the extra capacity after the first, second, and third replacements?
 

DrKK

FreeNAS Generalissimo
Joined
Oct 15, 2013
Messages
3,630
al451 is correct, of course. One of the best-known limitations of ZFS is the fact that an existing vdev cannot be expanded, unless you replace each and every device in the vdev with a larger device. One they have *ALL* been replaced, then the volume *should* increase to the new size. However: I recently have had two users for which it did NOT automatically increase in size. In that case, it has to be done manually from the command line.
 

Jon Smark

Dabbler
Joined
Aug 29, 2016
Messages
37
Thanks for the clarification, guys! Yes, this limitation is mildly annoying, but not a deal breaker.
 

Nick2253

Wizard
Joined
Apr 21, 2014
Messages
1,633
To maximize expansion options, consider striped mirrors.
I'll second this: if you have the money and/or the physical space, there are many benefits to striped mirrors. Other than the easy of expansion, striped mirrors will also give you much better performance than a RAIDZx vdev.

However, you want to make sure you have a spare on and, since the failure of both drives in a mirror will mean the loss of the entire pool.
 
Status
Not open for further replies.
Top