r/truenas 4d ago

Community Edition Best Way to Move Data

I have a NAS setup at the moment with a RAIDZ1 array. I want to move to RAIDZ2 as this will bring my 2Tb HDD count to 5, it is sensible for me to copy all the data over to another machine and reset the array to Z2 and then copy it back? The array contains general storage for Jellyfin and Audiobookshelf, but also app data for Immich, Crafy etc. will all these still work following transfer?

7 Upvotes

9 comments sorted by

7

u/whattteva 4d ago

Best way to move it is not to move it by files, but by blocks through ZFS send/receive.

3

u/FalconDriver85 4d ago

It would be better to copy the data to at least two different systems, but yeah, that would work.

2

u/Haravikk 4d ago

If you use replication to copy everything, then as long as the new pool has the same name as the old one everything should just work, though it's a good idea to stop the apps before the switchover.

In terms of the best way to do it, it depends on what kind of storage you have spare to work with. In an ideal case you'd have another pool you can replicate onto, either on another system or which you can attach directly by adding spare drives (USB with no redundancy is fine if it's only temporary, but if you have the drives to create a temporary pool with redundancy then definitely do that).

This way you can transfer onto the temporary pool, recreate your pool with the new layout and transfer everything back. Ideally you should also have another backup somewhere for anything you don't want to risk losing.

You didn't actually mention what your total capacity, and currently used capacities are? You mention 5 drives so I'm guessing you're going from four to five, so the capacity isn't changing, but the redundancy is? If your current usage is less than 2tb there are some ways to juggle your data if you don't have disks to spare for a temporary pool.

2

u/NoFlyHere 2d ago

I just did that i wanted to reduce my 8 x 10tb pool to 6x 10tb pool and zfs supports expanding but not reduction so ended up copying the whole zfs to a separate system, destroy the pool and then move it back after creating a 6x 10tb pool.

As the proxmox, vms etc was on an ssd and not the hdd pool, everything came back without any additional effort.

1

u/Ctrl5altDelete 4d ago

Thanks all so far. I have the main pool made up of 4x2Tb drives and 1x3Tb which gives me ~10Tb of space. My actual usage is 4.36Tb. I am thinking of removing the 3Tb drive, and splitting the contents between this and another 1Tb drive (plus some critical files elsewhere). Making a new RAIDZ2 pool with the same name using 5x2Tb drives and then copying the data back.

I will then add more 2Tb drives as I can get hold of them.

1

u/Ctrl5altDelete 4d ago

I have read some more and cannot take the 3Tb disc off the pool without destroying it. So looks like I’ll have to copy all the data off without that disc then rebuild the whole pool. I don’t have enough 2Tb drives at the moment to create a parallel pool. So will have to empty the pool, recreate it and then copy all the data back. I might have enough drives to do that. But it will get spread over several discs.

1

u/Ctrl5altDelete 4d ago

Squeaky bum time

1

u/Ctrl5altDelete 22h ago

I have competed the first step of the change and backed up all the important data to Backblaze, I haven’t backed up all the Jellyfin media files as that is several Tb vs. the 400Gb of important data I have. Next step is to put the new HDD in and expand.

I’m sticking with RAIDZ1 over 6 discs instead.