Solved! How to remove a drive from an UnRAID array


Taige

8 posts in this topic Last Reply

Recommended Posts

I'm new to UnRAID having used it for about a week now.

 

I found this link telling me how to remove a drive from my array:

https://www.lime-technology.com/wiki/index.php/Replacing_Multiple_Data_Drives_with_a_Single_Larger_Drive

 

I'm at the point where I've removed the drive I wanted to remove (after rsync'ing the data to another drive)...  

The linked procedure says "Use New Config to unassign removed drive(s)."  

 

Where is this in the webGUI?  

 

I've unassigned the drive, but the option I get for Array Operation is:

"Start will disable the missing disk and then bring the array on-line. 
Install a replacement disk as soon as possible."

 

I don't want to start it with UnRAID assuming I want to eventually replace the missing disk.

 

How do a new a "new config"? Is this terminology from an older version of UnRAID?

 

Edit:  Nevermind!  I found it under Tools.  I should have just looked around a bit more before posting.  Sorry!

Edited by Taige
Solved my own problem.
Link to post

Look on the tools tab.

 

Many people with unRAID arrays become somewhat anal about having parity protection. A second without it is a second when you are at risk for data loss if a drive fails. Rebuilding parity is a relatively slow process, and until it is done you are not protected. For that reason, many people prefer not to remove a disk if they can help it. After all, eventually you'll need more space. 

 

But it is pretty easy to do. You just tell unRAID to foget about your current array (New Config) and then redefine the array without the disk you wanted to remove. Just make sure to assign regularly parity to parity. If you have dual parity, you'd have to rebuild the second parity (probably best to leave it out, and then add it back after the new array is started and stopped once. And it would rebuild it.)

 

There is a trickier way taking advantage of the fact that a drive full of binary zero is "invisible" to parity. So you can fill a disk with zeroes while it is in the array, then do the New Config telling it to trust parity. And define the array without that disk, telling the New Config to trust parity. Because you zeroed out the disk, parity will still be accurate. And you would have silently removed the disk (destroying any use of the disk as a backup of the data is contained). You can do a fancier trick to pull out two drives - just clone a disk (sector by sector). Two identical disks cancel each other out parity wise (at least single parity, maybe not dual) . But anyway, I digress .. :) 

 

I used to be the kind of person that looked for these "maintain parity at all costs" methods, but not any more.

 

Instead, I recommend running a parity check before removing it, and looking at the SMART attributes for every disk, before and after. By comparing the before and after values, you can see if any of the disk is having signs of impending failure. Values like reallocated sectors and pending sectors on the rise are danger signs. If you see these problems it is not a good time to remove a disk (except THAT one)! But if the before and after SMART values for these are both 0, and nothing else is looking concerning, doing the new config and rebuilding parity is very low risk.

 

Enjoy your array!

  • Like 1
  • Thanks 1
Link to post
  • 3 years later...

When is there going to be an automatic procedure for this? Like a "prepare drive for removal" button, a "prepare drive for decommissioning" button and then also a "securely erase decommissioned drive" button. Is there a feature request that is already being worked on?

On 4/27/2017 at 11:37 AM, SSD said:

it is pretty easy to do. You just tell unRAID to foget about your current array (New Config) and then redefine the array without the disk you wanted to remove.

At this point it could alert you that you have useful data on the "decommissioning" drive and do this for you... (and by doing this for you, I mean moving the data to free space on the array for you, maintaining data safety)

Edited by skidaddl3
Link to post
  • 1 month later...

I was just about to migrate data from 2 x 2TB disk to a single 8TB disk and then remove the 2 x 2TB drives to get back some disk bays. I didnt realise the removal process was so painful. I just added a 14TB parity disk yesterday (future proof!) and really dont want another parity check so soon (though understandable if unavoidable). But, a simple 'remove disk' option which says to poweroff, remove disk and then poweron again would be very welcome to ease my worries. Creating a new config seems a bit scary, though i'm sure I would be fine, it seems a bit against the grain to do something so drastic for a procedure most people will do at some point.

Edited by rootisgod
Link to post
16 minutes ago, rootisgod said:

I was just about to migrate data from 2 x 2TB disk to a single 8TB disk and then remove the 2 x 2TB drives to get back some disk bays. I didnt realise the removal process was so painful. I just added a 14TB parity disk yesterday (future proof!) and really dont want another parity check so soon (though understandable if unavoidable). But, a simple 'remove disk' option which says to poweroff, remove disk and then poweron again would be very welcome to ease my worries. Creating a new config seems a bit scary, though i'm sure I would be fine, it seems a bit against the grain to do something so drastic for a procedure most people will do at some point.

Since the removed disks are part of parity, parity is invalid until rebuilt without those disks. So there is going to be some process involved which takes some time. Providing an automated way to do it has probably not been a high priority since it isn't often needed and there are well documented ways to do it yourself.

 

Why did you want to "get back some disk bays" though? If the purpose is so you can add larger disks to the array instead of those smaller disks, then there is no need to "remove" anything. Just replace the smaller disks with the larger disks and let it rebuild (one at a time).

 

Link to post
3 minutes ago, trurl said:

Since the removed disks are part of parity, parity is invalid until rebuilt without those disks. So there is going to be some process involved which takes some time. Providing an automated way to do it has probably not been a high priority since it isn't often needed and there are well documented ways to do it yourself.

 

Why did you want to "get back some disk bays" though? If the purpose is so you can add larger disks to the array instead of those smaller disks, then there is no need to "remove" anything. Just replace the smaller disks with the larger disks and let it rebuild (one at a time).

 

I didn't look at it that way before actually, replacing when I actually have a new disk is better. Plus it makes it one step, thanks!

So, could I in theory just rip out disk x, insert a blank new one of higher capacity, tell it to use that as the new disk x, then parity recovers all the data for me to the new disk? Or would that be a bit daft to rely on and it would be better to migrate data off to an existing disk first (using unbalance say) assuming I had existing space elsewhere on the array to do that?

Link to post
13 minutes ago, rootisgod said:

So, could I in theory just rip out disk x, insert a blank new one of higher capacity, tell it to use that as the new disk x, then parity recovers all the data for me to the new disk?

Except for that "rip out" part. Hot swap isn't recommended in the array, and wouldn't help anyway since you still must stop the array in order to assign the replacement disk. So stop the array and shutdown to replace the disk. Then assign the new disk to the same slot and start the array to begin rebuilding.

15 minutes ago, rootisgod said:

Or would that be a bit daft to rely on and it would be better to migrate data off to an existing disk first (using unbalance say) assuming I had existing space elsewhere on the array to do that?

More trouble to do it that way with no added benefit. Just keep the original disk until you are satisfied the rebuild was successful.

Link to post

Yup, I meant a 'safe' rip out! I'm not that crazy.... Great, that's very helpful. I also forgot that the original disk still has the data so I really can't lose. Thanks very much!

 

Though you may have just cost me hundreds in new hard disks ;)

 

EDIT:
I checked the new config tool just to be sure what it did, and it does seem to have a preserve option so you dont have to be super paranoid about putting things back as they were after removing some disks. So i take back my original suggestion somewhat, it seems to do the job nicely. Relevant part highlighted in green.
 

Quote

 

FROM THE NEW CONFIG TOOL SCREEN
This is a utility to reset the array disk configuration so that all disks appear as "New" disks, as if it were a fresh new server.

This is useful when you have added or removed multiple drives and wish to rebuild parity based on the new configuration.

Use the 'Preserve current assignments' selection to populate the desired disk slots after the array has been reset. By default no disk slots are populated.

DO NOT USE THIS UTILITY THINKING IT WILL REBUILD A FAILED DRIVE - it will have the opposite effect of making it impossible to rebuild an existing failed drive - you have been warned!

 

 

Edited by rootisgod
Info update
Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.