advice on how to upgrade my disks - how does the detach and replace option work?

Joined
May 18, 2020
Messages
7
hi all

im looking at upgrading some of my disks in my freenas to a larger size. Ideally id like to change one disk at a time and let the pools rebuild.
my freenas version is 11.3-U5

im a bit confused as to what the process would be so thought id ask to get a better understanding of the process before i go breaking anything.

zpool status shows that my pools have the following configuration.

Pool1 - raidz1-0
4x 2TB disks in this pool

Pool2 - mirror-0
2x 6TB disk in this pool


with the configuration above am i able to simply detach a disk from a pool and put a larger disk in and let it rebuild and then do that with the next disk?
if i detach (select the detach option, not physically pull the disk out) a disk from a striped raid (pool1) would that kill the raid or would that simply remove a disk and reduce capacity?
my understanding is that i should be able to put a disk in Pool2 into offline mode and detach and then attach a new disk and hit replace so it rebuilds.. is this correct?


i am fairly new to freenas so let me know if you need any more info


appreciate any help with this one


cheers!
 

Etorix

Wizard
Joined
Dec 30, 2020
Messages
2,134
Detach reduces redundancy but not capacity. You can offline disks and replace but, if you have a spare SATA port, the best way is to plug in the new drive and then replace (Storage>Pool>gear>Status, (old drive)>3-dot>Replace). This way you resilver with full redundancy; the old drive will automatically go offline once it's done.
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,703
if i detach (select the detach option, not physically pull the disk out) a disk from a striped raid (pool1) would that kill the raid or would that simply remove a disk and reduce capacity?
I can't remember exactly how the options presented in 11.3, but detaching a disk from RAIDZ1 isn't possible (regardless of version, ZFS just can't do it at this time). You can offline it and replace it with a new disk though and after all are replaced, the pool will grow in capacity.
 
Joined
May 18, 2020
Messages
7
Detach reduces redundancy but not capacity. You can offline disks and replace but, if you have a spare SATA port, the best way is to plug in the new drive and then replace (Storage>Pool>gear>Status, (old drive)>3-dot>Replace). This way you resilver with full redundancy; the old drive will automatically go offline once it's done.

unfortunately i dont have a spare SATA port to plug in a new drive. wish i did, would definitely make life a lot easier.

so i can offline the disks one at a time, replace the disks and then once completed the pool size will grow.
its obviously a more risky approach but i think its the only option i have.. just need to make sure i select the correct disk when im physically unplugging them.

is there anything else i need to be aware of in regards to this?
any other settings / options i need to look at?
 
Joined
May 18, 2020
Messages
7
I can't remember exactly how the options presented in 11.3, but detaching a disk from RAIDZ1 isn't possible (regardless of version, ZFS just can't do it at this time). You can offline it and replace it with a new disk though and after all are replaced, the pool will grow in capacity.

thank you for the info.
from the sound of it i have to go down the path of offline each disk and replace one at a time to get these disks replaced with a bigger size.
 

Chris Moore

Hall of Famer
Joined
May 2, 2015
Messages
10,080
unfortunately i dont have a spare SATA port to plug in a new drive. wish i did, would definitely make life a lot easier.
Perhaps it is time to get a SAS HBA so you can have more ports. Then you could connect all your new drives in a RAIDz2 pool and copy all your data over to the new, better pool. Disks larger than 2TB are not a good idea with RAIDz1 and one way mirrors are not horrible, but there are better solutions.
 
Joined
May 18, 2020
Messages
7
Perhaps it is time to get a SAS HBA so you can have more ports. Then you could connect all your new drives in a RAIDz2 pool and copy all your data over to the new, better pool. Disks larger than 2TB are not a good idea with RAIDz1 and one way mirrors are not horrible, but there are better solutions.

im actually considering wiping the raidz1 pool and creating a proper mirror pool with the new disks.
the existing disks are 2TB each.. but the new ones i can use are 6TB.. so mirror would definitely make more sense here.

just need to backup the data on it and zap the sucker!
 

Etorix

Wizard
Joined
Dec 30, 2020
Messages
2,134
from the sound of it i have to go down the path of offline each disk and replace one at a time to get these disks replaced with a bigger size.
An alternative would be to export one pool, unplug its drives and use the ports to replace drives in the other pool. But that would not solve the issue with raidz1 not being a secure option, so you'd be better buying (or borrowing) a HBA in order to migrate this raidz1 pool to a raidz2 (or, ideally, 3-way mirror).
 
Joined
May 18, 2020
Messages
7
thanks for all the input... im gonna first start off with my mirror pool
take 1 of the disks offline then replace the drive with a bigger disk and hope for the best

ill take a backup of what i can from that pool first just incase it all goes pear shaped

with the raidz1 pool i will most likely zap this and rebuild it as a proper mirror pool... especially since ill have bigger disks to use.
i think thats the best approach here


would i get any benefit from updating my freenas version to truenas 12.0 ?


ill post back!
 
Joined
May 18, 2020
Messages
7
so ive finally gone ahead and replaced one of the disks...

so i set one disk as offline
i then replaced the disk and added the new one in

but the disk wasnt properly detected and wasnt showing up in the disk section.
i restarted my NAS and when it came back on i could then see the new disk attached.

i tried to bring the disk online but the pool was still degraded.

eventually i found the option to wipe the disk and after is when the disk showed up as online and OK but the pool still couldnt see the new disk.
i couldnt find a rescan option or detect new disk in pool... so im not really sure whats going on here.

the only thing i could do is remove the old disk from the pool and only then was i able to re-add/extend the pool with the new disk.
and this doesnt sound right to me as the pool is now extended rather than a proper mirror...


does anybody know what ive done wrong?
is there a step / rescan / re-add option that ive missed?


thanks
 
Top