SOLVED Changing volume type when adding disks

Status
Not open for further replies.

Baz_Zerg

Cadet
Joined
Oct 23, 2017
Messages
2
Hi,

Newbi on this forum, and to FreeNAS in general. Hope my question is not to brain-numming, but have googled without finding any real answer.

I am considering building a NAS running FreeNAS, but to start cheap and then expand as the need grows, I were thinking of doing below:

1. Start with 2 HDD in ZFSmirror.
2. When needed, expand with 3th disk, converting to RAIDZ1
3. When needed, expand with 4th disk
4. When needed, expand with 5th disk
5. When needed, expand with 6th disk
6. When needed, expand with 7th disk

My question is. Is it possible to do the conversion from ZFSmirror to RAIDZ1 without loosing the already stored data, ore having to move it elsewhere?

Also, I were considering adding a second recovery disk (RAIDZ2) as disk count went up. I assume that it will not be a problem to migrate from RAIDZ1 to RAIDZ2 without data-loss, when adding a new disk?

Best Regards
 

Artion

Patron
Joined
Feb 12, 2016
Messages
331
I suggest you to dig more on how zfs works.

Basically you create a pool on top of vdevs, one or more vdevs. Each vdev can be a single disk, two or more disks in mirror, three or more disks in RAIDZ-n, n going from 1 to 3 that is the number of disks a vdev can tolerate loosing without comprimising data.

If a vdev become unavailable, the whole pool is lost (the data is stripped across all vdevs members of a pool) .

You can not change the configuration of a vdev after its creation. The only way is to destroy it (and the data it contains) and rearrange the disks to a new configuration. (Well, in future versions maybe possible to modify RAIDZ-n configurations. Actually you can only attach/detach disks to a mirror configuration and in the near future to a RAIDZ-n one)

But you can add as much vdevs to a pool as you want/can. :)
 
Last edited:

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
Is it possible to do the conversion from ZFSmirror to RAIDZ1 without loosing the already stored data, ore having to move it elsewhere?
No, it is not.
I assume that it will not be a problem to migrate from RAIDZ1 to RAIDZ2 without data-loss, when adding a new disk?
You assume incorrectly.
 

Glorious1

Guru
Joined
Nov 23, 2014
Messages
1,211

Baz_Zerg

Cadet
Joined
Oct 23, 2017
Messages
2
Hi,

First off. Sorry for late reply.

@Artion & @danb35
Thanks for the feedback.

I understand that vdevs are pooled togeather, but had hoped for some flexibility in converting pools between types after creation. I knew that mirrow to RAIDZn probably were a stretch, but I had hoped for conversion between RAIDZn's.

@Glorious1
I will read through you link. Thanks inadvance.

Best Regards.
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
but had hoped for some flexibility in converting pools between types after creation.
There is no current ability to do so, and nothing on the horizon promising this capability either. It sounds like the OpenZFS devs are making good progress on being able to expand a vdev--for example, turn a three-disk RAIDZ1 vdev into a four-disk RAIDZ1 vdev--but as yet there's no planned ability to turn RAIDZ1 into RAIDZ2.
 
Status
Not open for further replies.
Top