Change Mirror to RAIDZ1

I have seen some posts on this topic but they don’t seem to answer my question or don’t give quite the detail I need. I am new to TrueNAS Scale and I am using it only at home for domestic use, so I do not store critical business data etc and I have simple needs.

When I first set it up I had two physical 6TB disks and I chose to setup a mirror (IIRC I didn’t have a choice with only two disks). I have now got a third 6TB disk and would like to use it to expand the space available. I think this means I need to change from a mirror to RAIDZ1. I have seen that it isn’t recommended for disks greater then 1TB, but given that this is for non-business use I suspect that this isn’t really an issue in my case (or is it?).

I am wondering what the best process is to convert to RAIDZ1 without losing data and without losing my configuration of datasets etc? I am happy to take the risk of being vulnerable to a disk failure during the conversion process, again because of the nature of the data.

Given all this, are the steps as follows?

  1. Remove a disk from the mirrored pool.
  2. Create a new pool from the three disks?

If so, then I am not sure about the second step in the sense that I don’t know how to make sure the data is preserved and the configuration of datasets etc is preserved. Should I just wipe the lot and start again? I would prefer not to if I can avoid this.

Thanks for any advice.

Business or not, how happy would you if you were to lose the data? (Family pictures/movies, etc…)

Then your process is:

  • Remove a disk from the mirror (or split it).
  • Create a 3-wide raidz1 with the new disk, the disk you have removed and a sparse file. (CLI required. Here be dragons!)
  • Remove the sparse file, to end up with a degraded raidz1.
  • Replicate your data from the single-drive mirror to the degraded raidz1. A recursive replication from the root dataset will preserve your configuration.
  • Export the old pool, and add its drive to the new raidz1 pool to replace the missing sparse file; let the pool resilver.
  • Optionally, rename the new pool with the old name so you don’t have to adjust the path to your shares.

Very simple: You can’t preserve data. Drives are instantly erased at the moment they are added to a pool, or used to create one. Hence the replication, and multi-step process above.

Obviously, it would be easier and safer if you had more drives and could replicate without intermediate steps with degraded pools and/or end up with a raidz2.

1 Like

Thanks, I will study your recommendations carefully. The data I have on the NAS is mostly just backups of other data I already have elsewhere. I could trash it and start again, but I would like to see if it is possible without doing this and perhaps learn some new stuff along the way.

Similar to this, if you have a large enough external USB drive, you can create a temporary single-drive pool and replicate everything to it.

Then create a new RAIDZ1 pool with your three HDDs.

Then replicate everything from the USB to the RAIDZ1 pool.

The USB drive’s performance and reliably is not as important as some warnings would infer:

  1. You’re not using it to access your data indefinitely
  2. You already have a copy of all your data on another pool

Step 1

flowchart LR

style pool1 stroke:green,stroke-width:4px

hdd1[(HDD 1)]
hdd2[(HDD 2)]
hdd3[(HDD3)]
usb[(USB)]
pool1((Mirror Pool))

hdd1 o===o pool1
hdd2 o===o pool1

pool1 -..-|replicate| usb

Step 2

flowchart LR

style pool1 stroke:green,stroke-width:4px

hdd1[(HDD 1)]
hdd2[(HDD 2)]
hdd3[(HDD3)]
usb[(USB)]
pool1((Stripe Pool))
pool2((RAIDZ1 Pool))

hdd1 o===o pool2
hdd2 o===o pool2
hdd3 o===o pool2
usb o===o pool1

Step 3

flowchart LR

style pool1 stroke:green,stroke-width:4px
style pool2 stroke:green,stroke-width:4px

hdd1[(HDD 1)]
hdd2[(HDD 2)]
hdd3[(HDD3)]
usb[(USB)]
pool1((Stripe Pool))
pool2((RAIDZ1 Pool))

hdd1 o===o pool2
hdd2 o===o pool2
hdd3 o===o pool2
usb o===o pool1

pool1 -..->|replicate| pool2

Finished

flowchart LR

style pool2 stroke:green,stroke-width:4px

hdd1[(HDD 1)]
hdd2[(HDD 2)]
hdd3[(HDD3)]
pool2((RAIDZ1 Pool))

hdd1 o===o pool2
hdd2 o===o pool2
hdd3 o===o pool2
3 Likes

Thank you for such a clear reply. I will have to see if I have something suitable I can use as this seems quite a good method too.

Bewae of the mermaid song… :wink: