Add another HD

Status
Not open for further replies.

avalon60

Guru
Joined
Jan 15, 2014
Messages
597
I presently have x3 2TB WD hardrives in Raidz1 setup. I am getting another 2TB WD Hhard drive, and want to add this to my current setup.
Eventually, sometime later this year, I will get another of the same HD and add that. Ultimately I want to change the setup from raidz1 to raidz2.

What is the best way to do this?
 

avalon60

Guru
Joined
Jan 15, 2014
Messages
597
So can I have raidz2 with just 4 drives, as I though there had to be 5 drives for raidz2.
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
Nope--the minimum is 3 disks for RAIDZ1, 4 disks for RAIDZ2, and 5 disks for RAIDZ3. A 5-disk RAIDZ3 array might be kind of silly, but it's still viable.

Of course, a 4-disk RAIDZ2 array uses half of its capacity as parity. You could instead do a pair of mirrors, and have the same capacity, better performance, but somewhat worse redundancy. Expanding that in the future could be as easy as adding another pair of disks, or replacing two disks with larger ones. In short, you'd have a little more flexibility with the mirrors, but redundancy would still be a little better with RAIDZ2.
 

avalon60

Guru
Joined
Jan 15, 2014
Messages
597
I would rather go with better redundancy or less chance of losing my data if one drive fails etc.

withe the 3 disk raidz1 setup I have something like 3.6TB of space of which I have 2.1TB left. I know I don't need another drive yet, but as I said, would rather go for safety.
 

depasseg

FreeNAS Replicant
Joined
Sep 16, 2014
Messages
2,874
You also know that you can't just add 1 drive at a time to expand capacity, right?
 

avalon60

Guru
Joined
Jan 15, 2014
Messages
597
Well yes and no. I thought so but wasn't sure, which is why I asked. So when I add the other 2TB drive , do I just import the disk.
 

depasseg

FreeNAS Replicant
Joined
Sep 16, 2014
Messages
2,874
You can add drives, but once you have a vdev (like a 4 disk Raid Z2), you can't modify it. You can add another vdev. In other words, if you created a 4 disk Raid Z2 vdev and then added a single drive, if you lost that one single drive, you would lose everything. There is a huge warning telling you about this possible loss, but it still happens unfortunately.
 

avalon60

Guru
Joined
Jan 15, 2014
Messages
597
Ok, so now I am confused!

Is it now better to leave it as a 3 disk raiz1, or better to add another disk to make a raidz2 setup, and then not adding any more drives.
It seems to me that a raidz2 with 4 disks is not a very good or safe way to keep data.
 

depasseg

FreeNAS Replicant
Joined
Sep 16, 2014
Messages
2,874
It's all about willingness to accept risk and the amount of effort and resources you want to put into this.

To migrate from a 3 disk raidz1 to a 4 disk raidz2 will require you to destroy that pool, add the new drive and then create the 4 drive raidz2. Do you have somewhere else to store your data during the transition?

As for the acceptance of risk, what do you think the likelihood is of having 2 out of 3 drives fail at nearly the same time, what about 3 out of 4. That's the difference between 3 disk raidz1 and 4 disk raid z2. 4 disk raidz2 is better protection, but at the cost of another drive.
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
Let's maybe back up a bit. Without RAID, if a disk fails, you lose whatever is on that disk. Backups are one way to protect against that; another way is RAID. RAID adds some degree of redundancy, so you can lose one or more disks without harm to your data.

With your current three-disk RAIDZ1 pool, if a single disk fails, your data remains intact. However, any corruption to the remaining data can't be corrected. Depending on where it is, it's possible for that corruption to be catastrophic.

By contrast, a RAIDZ2 pool can tolerate the loss of two disks without losing any data. RAIDZ2 is, by any measure, safer than RAIDZ1. The next level, of course, is RAIDZ3, which can tolerate the loss of up to three disks. This is overkill for most folks, and the increased performance penalty is often unacceptable.

The comparison between a four-disk RAIDZ2 pool and striped mirrors is a bit closer. Both can tolerate the loss of two disks, but with mirrors, they have to be the "right" two disks. If you have, for example, disks 1 and 2 mirrored, and disks 3 and 4 mirrored, you can lose disk 1 or 2 and disk 3 or 4, and your data will be fine. However, if you lose disks 1 and 2, or 3 and 4, all your data will be lost. In this regard, RAIDZ2 is better, because it can tolerate the loss of any two disks. However, the mirrors will perform better, and are more flexible when it comes to upgrading your capacity in the future.
 

avalon60

Guru
Joined
Jan 15, 2014
Messages
597
Ok, I do have somewhere to locate the data on my nas box, well I'll make some space somewhere.

When I get the other disk, I will make a start moving the data, and then add the disk to make a RAIDZ2 configuration.

Thanks for all the replies, and I know what to do now, I think!
 

avalon60

Guru
Joined
Jan 15, 2014
Messages
597
I have installed a new 2TB WD Red hard disk in my NAS box and it is showing when I click 'View Disks' .

So when it comes to starting from scratch with a RIDZ2 setup, do I just delete the cif share , in /sharing /windows CIFS on the exsisting shares volume of x3 2TB disks.
 
Last edited:

gpsguy

Active Member
Joined
Jan 22, 2012
Messages
4,472
If your "nas box" is your FreeNAS server, you didn't understand the directions. You need to move the data somewhere else, since you need to destroy the pool and start over. By "destroy" we mean erasing the content on the existing drives and starting over.

I have installed a new 2TB WD Red hard disk in my NAS box and it is showing when I click 'View Disks' .

So when it comes to starting from scratch with a RIDZ2 setup, do I just delete the cif share , in /sharing /windows CIFS on the exsisting shares volume of x3 2TB disks.
 

gpsguy

Active Member
Joined
Jan 22, 2012
Messages
4,472
avalon60, the 2nd part of my reply just disappeared, give me a few minutes to rewrite it.

I have installed a new 2TB WD Red hard disk in my NAS box and it is showing when I click 'View Disks' .
 

gpsguy

Active Member
Joined
Jan 22, 2012
Messages
4,472
If's more than just deleting a share - we have to delete/erase everything.

Look at "detach volume" in the manual. You'll want to check the box to mark the disks as new. Please ensure that you have a backup on other media, etc. before you do this and that you understand what will happen.

"If you do check the box to mark the disks as new, the volume and all of its data, datasets, and zvols will be destroyed and the underlying disks will be returned to their raw state."

Once you've done this, you can take your 3 old disks, add your new disk, and create a new RAIDz2 volume. Then create your shares, etc. And, at some point, transfer the data from your backup media to the new volume.

I have installed a new 2TB WD Red hard disk in my NAS box and it is showing when I click 'View Disks' .
.
 

avalon60

Guru
Joined
Jan 15, 2014
Messages
597
Ok, when I put 'detach volume' in the freenas 9.3 docs search box, nothing is found. So I then just put 'volume', and again nothing is found.

So scrolling through each section under 'Storage', I can't see anywhere where it says 'detach volume'

Edit: I did find 'detach volume' under 'Viewing volumes', and I see it all now, ie what I want to or need to know.
Thanks
 

stranger

Dabbler
Joined
Apr 11, 2014
Messages
31
I have a similar problem in that I also thought that RAIDZ1 would be enough for me but now realise that my data is too valuable to me and need to migrate to RAIDZ2. I'd like some criticism/review/suggestions for my plans.

First I've done a backup over rsync to an ext4 filesystem on a usb drive.

I've got 3 x 2Tb disks in RAIDZ1 now. I bought another 2Tb to add to make it RAIDZ2 and another 3Tb empty disk that I will use for another purpose. My intention is to migrate the data and most, if not all snapshots to a 4x2Tb RAIDZ2 pool. I'm still on FreeNAS 9.2 and may upgrade this too, but probably after this Z1->Z2 migration.

My data is about 1Tb, so I was thinking of splitting my 3Tb disk in two and adding the new 2Tb disk to a degraded Z2 pool - using a file device. I suppose I will do it on the command line, then export and import the pool into the gui.
Then I would copy the first snapshot to this new pool with zfs send/receive. Then the other snapshots. Finally I would remove a disk at a time from the Z1 pool and add to the Z2 pool. Preferentially removing the degraded pool status then the 3Tb disk.

This is all very hand waving at the moment so if anyone already knows if such a procedure has been written up I'd appreciate it. I presume that once I've removed the 1.5 Tb disks (each half of the 3Tb disk) and replaced with with the 2Tb disks that the whole pool will be 2Tb. Is that correct?

Thanks in advance for all comments
 
Last edited:
Status
Not open for further replies.
Top