RAID10 to RAID5 migration advice

indivision

Guru
Joined
Jan 4, 2013
Messages
806
Hello.

I am running the latest TrueNAS Core on a 4x2TB WD Red system as a RAID10. It has been going strong for 6 years now with no drive replacements. Storage is getting a bit tight lately and redundancy isn't that critical (a remote backup system is in place). So, I'm considering migrating from the RAID10 to a RAID5 in order to gain some additional storage.

I've been reading up on what I will need to do. But, can't seem to find a tutorial or guide that completely covers these operations. So, am hoping someone here can give some advice on how best to approach this. My goal is to end up with the same drives in RAID5 instead of RAID10 without having to re-build the server from scratch.

My motherboard has 6 sata slots. I already have a spare, matching 2TB Red drive on hand and could pick up another one for this process (and might add that to the array for even more storage). But, one problem seems to be that I can't make a second RAID5 pool with only the 2 open SATA ports. I need 3 drives for that. So, not sure how to work around that? Detach one of the RAID10 drives and use that (feels a bit risky)? Maybe add some SATA ports (motherboard has a PCIE 2.0 x8 internal slot)?

As a side-consideration, I'm not really sure if I should go with RAID5 or RAIDZ1? When it comes to RAID, it seems like you can find an opinion from someone for using any level under any circumstance. It sounds like RAIDZ1 may have a few neat additional features. But, maybe doesn't perform as fast?

Any advice on how to approach this would be greatly appreciated!
 

ornias

Wizard
Joined
Mar 6, 2020
Messages
1,458
The big rule of raid5: don't use raid5, unless you would also use raid0 with the same data
 

Constantin

Vampire Pig
Joined
May 19, 2017
Messages
1,829
So you have 4TB presently and want to expand beyond... OK, so expanding while using the same disks without wiping the data would necessitate adding another 2TB mirrored VDEV (i.e. expanding out to 6TB of capacity) to your pool. If you have a reliable backup and want to change to RAID5 or whatever, then you certainly can reconstitute the pool drives but the data will be lost - this is not unraid or whatever where arbitrary disks can be added to the pool.

With 6 SATA slots, I'd consider going with a 6-drive Z2 array. That would get you up to ~8TB of pool capacity with better redundancy than you have now (in addition to the backup). I run Z3 here but that's because I am paranoid.
 

ornias

Wizard
Joined
Mar 6, 2020
Messages
1,458
Great advice @Constantin Thats actually what i'm doing to get a little more space out of 6 disks. :)
and Raidz3 is not bad either!
 

indivision

Guru
Joined
Jan 4, 2013
Messages
806
The big rule of raid5: don't use raid5, unless you would also use raid0 with the same data

Having run RAID10 for several years now has given me enough time to realize that I don't actually need redundancy. What I needed (and I suspect most home users need) is a good backup.

So, in fact, RAID0 (with a backup) would indeed probably be fine for me. I consider RAID5 or RAIDZ1 only because restoring the array from a single drive failure would be more convenient than rebuilding from the backup. If it failed due to a multi-drive failure it would not be a disaster. It would just be a slight delay.

If I had a client that was asking for redundancy/uptime I would certainly not consider RAID5. But, all things considered, it seems like a strange argument to say RAID5 is bad because it's not "safe" while at the same time saying that RAID is not a backup. If RAID is not a backup then safety should not be a consideration in regard to levels. It should be about redundancy and up-time needs.

Maybe I should just go with RAID0. Is the performance cost of RAID5 not worth the decent chance of being able to survive a dead drive?

So you have 4TB presently and want to expand beyond... OK, so expanding while using the same disks without wiping the data would necessitate adding another 2TB mirrored VDEV (i.e. expanding out to 6TB of capacity) to your pool. If you have a reliable backup and want to change to RAID5 or whatever, then you certainly can reconstitute the pool drives but the data will be lost - this is not unraid or whatever where arbitrary disks can be added to the pool.

With 6 SATA slots, I'd consider going with a 6-drive Z2 array. That would get you up to ~8TB of pool capacity with better redundancy than you have now (in addition to the backup). I run Z3 here but that's because I am paranoid.

Thank you. I'm not really wanting to go with Z2 because it sacrifices too much space for a feature (redundancy) that I don't really need. There is nothing on the server that I need to have on-line faster than I could obtain it from the backup. So, to me, it's just throwing money away. Though, I am open to other arguments about this that I may have missed?

It sounds like there is not an elegant way to do this. So, my process probably will look something like this:

A) Save FreeNAS configuration.
B) Nuke the drives.
C) Re-install FreeNAS.
D) Configure the drives as RAID5 (or RAIDZ if someone can point to benefit?)
E) Apply the saved configuration.
F) Re-populate the data from backups.

One annoying thing I can see with this is having to rebuild the jails. Probably some other things that aren't saved in config?
 

indivision

Guru
Joined
Jan 4, 2013
Messages
806
Another process I THINK is possible:

A) Detach ONE drive from the current array.
B) Install 2 additional drives in the 2 open slots.
C) Create a new RAID5 array from the 1 detached drive + the 2 new ones.
D) Use the FreeNAS GUI to move the system files to the new RAID5.
E) Move the jails to the new RAID5 (is this possible?).
F) Move the data via replication (I am simplifying this step based on another tutorial for this that I found here).
G) Detach pools. Re-attach only the new one. Rename. (Again stolen from this other migration tutorial).
H) Then add the original drives to the new array to expand the new RAID5 (is that possible to just add drives later)?
I) Enjoy.

Is the above possible? As mentioned, I am taking the data copy steps from another tutorial. But, adding the twist of removing a drive from the current array so that I can have the 3 drives needed for a new RAID5. All of this extra work is to make it possible to avoid re-doing server config, jails, users, groups, permissions, etc.

Is my thinking sound on this?

(Another possibility is to buy a PCIE sata card to run the 3 new drives so that I don't need to remove a drive from the current array. But, this is a little wasteful since I won't need the extra sata slots after the process is done.)
 
Top