**VIDEO GUIDE** How to replace/updrade a hardrive in your array


Recommended Posts

  • 1 year later...

Great video's, I also watched your preclear video.

I have a question please. I would like to upgrade one of my (5) data drives to a larger size (my parity drive is already larger).

I would like to preclear the new drive first. Is it OK to physically remove and replace the old data drive with the new one and start the preclear? Or do I have to leave the old drive in while I'm preclearing the new drive? I don't have the physical or MB capacity for more than (5) data drives at any one time. I replaced a drive a couple of years ago but didn't preclear it. This time I want to preclear.

Thanks

 

Since I posted this a few minutes ago, I've been reading the preclear thread and it looks like preclear might not be necessary anymore?

I'm running 6.5.3...

I have a few windows 10 boxes with free sata ports. Should I check my new 8tb wd drive with that?

 

 

 

 

Edited by Tom899
Link to comment

Pre-clearing the disk will not make the rebuild go any faster as the rebuild always writes to the whole disk.    The only purpose of pre-clearing in this case is to verify the state of the disk before introducing it into the unRAID array and in your case it sounds as if it would be more convenient to do this on one of your Windows systems using the disk manufacturer’s diagnostic tools.

Link to comment

With the recent update on this topic, I thought I would mention how I almost always do drive updates. I am not a videographer as my friend @gridrunner is, but I'll lay it out in concept.

 

It is very uncommon for me to have disks fail. I think in my 10+ years as an unRAID user, I've only had 1 fail once in the array. Even seeing SMART attributes start to increase is rare, and never been catastrophic because I have an early warning system.

 

What happens far more more often is that my drive count gets larger and larger and I reach a point where I'd like to add more capacity and I don't want to add yet another drive. For example, if my array contained 4 3T drives, 3 4T drives, 1 6T drive, and 1 10T drive (+ 10T parity), I might say those 3T drives are looking pretty small and kind of a waste of slots, and might have been in my array 5 years, so their chances of failing are on the rise. I could replace 3 of them with just a single 10T drive. And If I added 2 10T drives, I could replace all 4 and have at least 8T more space + 2 slots to enable me to easily grow my array. That might keep me fat and happy for several years.

 

In order for this strategy to work, I'd need a way to add the 2 10T drives to the server temporarily. I advise to always have at least one slot free (or easily freed), as there are many failure scenarios that require an extra disk. If I don't have the slots, I will sometimes remove a cache SSD and/or UD temporarily, or jerry-rig some type of external (as simple as laying the drive on the floor, label down (like a turtle), and cabling it to a controller and power). This can work fine for this short (few days) operation if you can ensure that no person or animal is going to disturb. And disable any VMs / dockers that need the drives you've disconnected. (There are also some hybrid methods that would require only 1 (or possibly no) extra slots).

 

I first preclear the new disks. (There have been some debates about not preclearing, but I think it is valuable and always do it. I know that there have been issues with the plugin [which I was not involved in except I did allow @gfjardim to bundle my "fast preclear" script version in his plugin]. If anyone wants a functioning version of the fast preclear script that is easily run in a screen session, feel free to PM me.) 

 

In parallel I'd sometimes do a parity check on my array. Before starting, I look at the smart attributes on all the drives, and after finishing I look at them again. If I am seeing issues with reallocated sectors, or other attributes that are starting to rise, I might reconsider how I do the upgrade. But mostly the parity check comes back clean and the SMART attributes are fine before and after. The fact that this overlaps with the preclears typically means no lost time. I might omit the parity check if one was already done recently and all is clear, or if I am concerned about one of the array disks. A full disk read (parity check) could weaken the drive further. Such a scenario might cause me to rethink the parity check. (But I still have parity protection so even if the disk failed, I'd not lose data).

 

I then configure the new disks as UDs. Format them. And using Krusader, midnight commander, cp / rsync in a "screen" session, or some other method, copy the data from the 3T disks to the 10T disks. Note I can copy data very fast because parity is not involved. I can also copy to both of them in parallel (from different 3T disks) with no slowdown. (If I try to copy data from 2 3T disks to the same UD, then it would slow down.) So if I copy 2 of the 3T to one 10T one after another, overlapped with copying the other 2 to the other 10T, it would take the same time as a full-speed copy of 6T (8-11 hrs). I will mention that this approach has a few other benefits:

 

  1. I have a lot of flexibility in terms on what data I copy to what 10T disk. If I have data from 2 shares that have organically grown onto the 3T disks, I might like to dedicate one of the 10T to one share, and other other one to the other share. I have a lot of flexibility to put the data onto whichever disk I want - or even to another disk in my array that has some available space. If I am doing a lot of this, I'll often create a shell script to do the coping so I account for all the data.
  2. The bathtub curve for disks failures points to higher than normal failures in the early use of the drive. I've observed this. Often the preclear finds them. But if preclear works and I see subsequent SMART issues or worse, read or write errors on a 10T disk, I can prevent it ever entering the array. I can just remove it, return it, and get a new drive. My array continues to operate and is fully parity protected.
  3. If I have a desire to change the filesystem, this is a perfect time to move to XFS or BTRFS. Copying file by file means I am not stuck with RFS on my 10T disk like a rebuild of a 3T RFS disk.
  4. Although not a huge problem, this method defrags the data. Using unRAID to rebuild a disk is going to take a mirror image. I already mentioned that this prevents moving to a different file system, but similarly, if the disk is fragmented due to a lot of adds, changes and deletes, the rebuilt disk will be identically fragmented.

So once the data is all copied to the 10T drives, I can do a new config, omit the 4 3T drives, add the 2 10T drives, and rebuild parity. (I can then physically remove and keep the 4 3T drives as backups). There is an very very small risk of a drive failing in building parity, and if you are worried about it there are ways to protect yourself. (If there are questions I can elaborate). But after doing a parity check just a day or two earlier, the chances are very low and I tend to just let it run. I have my critical data backed up, and any number of very unlikely risks - burglary, fire, PSU failing in a nasty way, etc. that I am accepting. I put this risk in the same probability as those.

 

Final step is to review your user shares and adjust include/exclude settings.

 

With this method, you are not only adding more data now, you are freeing slots to be able preclear and add new disks for the next 2 drive updates. And you're also able to remove all of the smaller drives from the array, which will normally have a very positive impact on parity check times.

 

(#ssdindex - Adding space to an array by replacing group of smaller disks)

Link to comment

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.