Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Adding a drive bigger than the parity drive

Featured Replies

I have a 2tb parity drive.  I recently purchased a 3tb drive.  I am looking for confirmation that I am correct in my thinking.  Since this drive is 3tb and my parity is 2tb I need to accomplish the following:

1.  Pre clear the 3tb.

2.  Remove the 2tb parity.

3.  Add the 3tb as a parity drive.  Allow the array to rebuild.

4.  Pre clear the 2th (old parity)

5.  Add the 2tb (old parity) to the array.

 

Does this sound correct?  Any suggestions, safety precautions etc?

 

Thanks for taking the time to read and help!

Step 1 is optional as a parity disk does not need pre-clearing.    However it is probably worth doing as a confidence test on a new drive.

You have the right steps.

 

1.  Pre clear the 3tb.

2a. Stop the array

2b.  Remove the 2tb parity.

3a.  Add the 3tb as a parity drive.  Allow the array to rebuild.

3b. Start the array Allow the array to rebuild.

4.  Pre clear the 2th (old parity)

5a. Stop the array

5b.  Add the 2tb (old parity) to the array.

5c. Start the array

 

 

Any suggestions, safety precautions etc?
You would be unwise to proceed without at least verifying that your array is fully healthy right now. I would first run a non-correcting parity check, then pull smart reports for all drives. You could accomplish those steps while the new 3TB was preclearing, and not spend any extra time. Doing a parity check while preclearing the new drive would also verify that your power supply, controllers, etc are up to the task of adding a drive.

 

If the parity check comes back with errors, I would stop right there and post back with the full syslog that includes the parity check, and also post the smart reports for all the drives. It wouldn't hurt to post the smart reports even if the parity check comes back clean.

  • Author

Thanks for the help.  I will be initiating a parity check.  I just purchased the 3tb drive from newegg, so it will be shipped.

If your original parity drive was precleared originally to make sure all was well with it and then was added as a parity. Now as hunter69 mentioned you wish to remove it to upgrade the parity size and reuse this drive in the array; what happens IF you took that old parity drive and didn't preclear it (again) and added it directly to the array as another addition (NEW) disk?

 

Would unRAID start a clearing of the drive or just give you the option to format it quickly and add it in?

Would unRAID start a clearing of the drive or just give you the option to format it quickly and add it in?

unRAID would have lost track of the fact that drive had been pre-cleared before using it is a parity drive.  Therefore you want to pre-clear it again before adding it as a data disk to minimize array downtime.

Would unRAID start a clearing of the drive or just give you the option to format it quickly and add it in?

unRAID would have lost track of the fact that drive had been pre-cleared before using it is a parity drive.

That is quite understood, thanks though (never hurts should someone else be reading this thread).

However, unRAID never really knew it was precleared to begin with though, as there is no signature check for a parity drive. Preclearing a drive that will be used for the parity drive assignment is just something (recommended) someone do to make sure the drive is OK to begin with (HW wise).

 

Therefore you want to pre-clear it again before adding it as a data disk to minimize array downtime.

So you are stating that removing the parity hard drive and assigning it as a data disk in the array would make unRAID start clearing the drive, not just formating it, is that correct?

 

 

----------

unRAID step 1 is no signature found on HD, clear the drive. (lengthy process array not available)

unRAID step 2 format the drive. (pretty quick, array is available)

----------

 

If your original parity drive was precleared originally to make sure all was well with it and then was added as a parity. Would unRAID start a clearing of the drive or just give you the option to format it quickly and add it in?

If it was written to at all, the preclear is no longer valid, and unraid would have to zero it before adding it. Clearing a drive writes zeros to the whole partition so the parity calculation is still the same when it is added. Using it as a parity drive would write all sorts of ones and zeroes all over it, so if you faked a preclear signature somehow the parity would be wrong at every location that had a one in it.

If your original parity drive was precleared originally to make sure all was well with it and then was added as a parity. Would unRAID start a clearing of the drive or just give you the option to format it quickly and add it in?

If it was written to at all, the preclear is no longer valid...

Agreed for any drive one wishes to add as a data drive, unRAID doen not have this check for a drive you assign to as parity, correct?

 

(continuation from aboce) ..., and unraid would have to zero it before adding it.

So that answers my question, thanks, it will start to clear the drive (thus array would not be available, if you do this with a drive that has not been currently precleared and not messed with).

 

..., so if you faked a preclear signature somehow the parity would be wrong at every location that had a one in it.

 

Off-topic, sorry to the OP ahead of time. This part I don't get, say a drive is not zero'ed out and a signature is faked, parity is written with all the 0/1 from this drive. As data is added to the drive it changes varies bits to 0/1's, so lets pretend I added 3 files only, and this drive fails I add a new one, wouldn't parity rebuilt these 3 files and whatever else (0/1's) it had from faking it out to begin with? thats what I am not completely understanding...

In addition to the fact that clearing the drive is necessary to add it to a protected array, you may feel you don't need to do that with the old parity drive, since it's been in use for a long time and thus is "known" to be a reasonably good drive.

 

If that's the case, you can easily avoid the need to pre-clear it ....

 

(a)  Do a parity check of your existing array (as already suggested and as you indicated you're doing).  Be sure it's a correcting check ... you do NOT want any uncorrected errors in the array before you start the upgrade process.

 

(b)  Physically install your new 3TB drive and do a pre-clear if you'd like to give it a thorough test [You could also do this on another system using the drive manufacturer's diagnostics instead of the pre-clear script].

 

(b)  Now do a "New Config" ... and set a configuration with all your current data drives AND the old parity drive as an additional data drive -- with NO parity drive assigned.    Start that array ... and it will format your "unformatted" drive (the old parity drive).    This will just take a few minutes.

 

©  Stop the array;  add the 3TB drive to the config as a parity drive;  and then Start the array ... it will now do an initial parity sync.

 

This process avoids the need to write zeroes to the old parity drive, since it's not being added to a protected array.

 

Off-topic, sorry to the OP ahead of time. This part I don't get, say a drive is not zero'ed out and a signature is faked, parity is written with all the 0/1 from this drive. As data is added to the drive it changes varies bits to 0/1's, so lets pretend I added 3 files only, and this drive fails I add a new one, wouldn't parity rebuilt these 3 files and whatever else (0/1's) it had from faking it out to begin with? thats what I am not completely understanding...

 

r.e. "... parity is written with all the 0/1 from this drive ..."  ==>  NO.  When a drive is added to your protected array, NO parity computations are done ... the drive is simply cleared to all zeroes to ensure that the current parity bit is valid.  IF, however, you add it to an unprotected array (i.e. no parity drive), then indeed when you add a parity drive and a parity sync is done, it will include this disk in that check => so the drive doesn't need to be cleared.

 

Off-topic, sorry to the OP ahead of time. This part I don't get, say a drive is not zero'ed out and a signature is faked, parity is written with all the 0/1 from this drive. As data is added to the drive it changes varies bits to 0/1's, so lets pretend I added 3 files only, and this drive fails I add a new one, wouldn't parity rebuilt these 3 files and whatever else (0/1's) it had from faking it out to begin with? thats what I am not completely understanding...

 

r.e. "... parity is written with all the 0/1 from this drive ..."  ==>  NO.  When a drive is added to your protected array, NO parity computations are done ...

Stop right there, no computations are done:

Question 1) because it thinks we have all zero's on the drive, correct?

Question 2) something has to change, as we added an additional drive for which it must now track and maintain parity for, no?

 

 

the drive is simply cleared to all zeroes to ensure that the current parity bit is valid.

 

Please read, I faked the signature on the drive i added, unRAID did not zero (clear) this drive out and just formated the files system, only. Parity does no computation, right, so I add three files to this new drive, and this drive fails a week later, I add a new one (allowing it to clear and format it), wouldn't parity rebuilt these 3 files on this new drive? if not what would it do? (I don't know, I am asking.)

In addition to the fact that clearing the drive is necessary to add it to a protected array, you may feel you don't need to do that with the old parity drive, since it's been in use for a long time and thus is "known" to be a reasonably good drive.

 

If that's the case, you can easily avoid the need to pre-clear it ....

 

(a)  Do a parity check of your existing array (as already suggested and as you indicated you're doing).  Be sure it's a correcting check ... you do NOT want any uncorrected errors in the array before you start the upgrade process.

 

(b)  Physically install your new 3TB drive and do a pre-clear if you'd like to give it a thorough test [You could also do this on another system using the drive manufacturer's diagnostics instead of the pre-clear script].

 

(b)  Now do a "New Config" ... and set a configuration with all your current data drives AND the old parity drive as an additional data drive -- with NO parity drive assigned.    Start that array ... and it will format your "unformatted" drive (the old parity drive).    This will just take a few minutes.

 

©  Stop the array;  add the 3TB drive to the config as a parity drive;  and then Start the array ... it will now do an initial parity sync.

 

This process avoids the need to write zeroes to the old parity drive, since it's not being added to a protected array.

 

Yes, but my personal take to this is  I rather preclear the drive ( you have options to make it skip a step to speed things up and only one pass) and add it to the array, versus unassign parity and issue a new config, and the smallest chance that lightning strikes you would be sorry.

But yes one could do as you stated in your steps.

 

 

Off-topic, sorry to the OP ahead of time. This part I don't get, say a drive is not zero'ed out and a signature is faked, parity is written with all the 0/1 from this drive. As data is added to the drive it changes varies bits to 0/1's, so lets pretend I added 3 files only, and this drive fails I add a new one, wouldn't parity rebuilt these 3 files and whatever else (0/1's) it had from faking it out to begin with? thats what I am not completely understanding...

 

Lets say you did all that. unRaid thinks the new drive has all 0's (zero's).

 

Lets say before you even add anything else to your array, a different drive dies.

unRaid now tries simulating the dead drive via the parity and all the other drives.

Wherever your faked drive has a 1, it will corrupt the "simulated" drive data with the reverse of what it should be.

 

Then if you tried to rebuild the failed disk, you just permanently corrupted data on the rebuilt drive but you wouldn't know it.

 

 

I rather preclear the drive ( you have options to make it skip a step to speed things up and only one pass) and add it to the array, versus unassign parity and issue a new config, and the smallest chance that lightning strikes you would be sorry.
That is exactly why Tom chose this particular path to add new data slots. Before the drive is included in parity protection, unraid must be sure it contains only zeros in the data area so the parity is maintained instead of being recalculated. If the preclear signature is found, unraid adds the drive with no verification of all zeros, otherwise the drive is zeroed before it is added.

 

There is a valid argument to be made that upgrading a drive by rebuilding from parity is a kludge, and unnecessarily risky. It would be better to temporarily use an extra physical slot and keep parity valid by creating a realtime copy of the disk to be upgraded and the new disk, then when the copy is done, zero the extra space, and start using the new drive and turn off the old drive, and allow it to be removed if hot swappable drive bays and controllers are in use.

Lets say you did all that. unRaid thinks the new drive has all 0's (zero's).

 

Lets say before you even add anything else to your array, a different drive dies.

unRaid now tries simulating the dead drive via the parity and all the other drives.

Wherever your faked drive has a 1, it will corrupt the "simulated" drive data with the reverse of what it should be.

 

I understand your scenario, thats cool we could go with that as well, we'll call it scenario#2.

 

I don't get why it would use anything (0/1) from this new drive to "simulate" the other failed drive?

I will explain my thoughts, garycase stated no computations are done (not disputing I don't know), and nothing has been written to the new faked added drive, so how more like why would this faked drive be utilized to help simulate any drive that was to fail?

There is a valid argument to be made that upgrading a drive by rebuilding from parity is a kludge, and unnecessarily risky. It would be better to temporarily use an extra physical slot and keep parity valid by creating a realtime copy of the disk to be upgraded and the new disk, then when the copy is done, zero the extra space, and start using the new drive and turn off the old drive, and allow it to be removed if hot swappable drive bays and controllers are in use.

That sound pretty cool.

Lets say you did all that. unRaid thinks the new drive has all 0's (zero's).

 

Lets say before you even add anything else to your array, a different drive dies.

unRaid now tries simulating the dead drive via the parity and all the other drives.

Wherever your faked drive has a 1, it will corrupt the "simulated" drive data with the reverse of what it should be.

 

I understand your scenario, thats cool we could go with that as well, we'll call it scenario#2.

 

I don't get why it would use anything (0/1) from this new drive to "simulate" the other failed drive?

I will explain my thoughts, garycase stated no computations are done (not disputing I don't know), and nothing has been written to the new faked added drive, so how more like why would this faked drive be utilized to help simulate any drive that was to fail?

 

When you add a precleared drive (or unRaid clears it), then unRaid knows that the new drive has all 0's, and therefore no parity computations are required since X+0=X....parity does not change.

 

But, when a drive fails, it is simulated by unRaid by taking the 1s & 0s of all the data drives plus parity drive to figure out what the bit should/would be on the failed drive.

 

 

I don't get why it would use anything (0/1) from this new drive to "simulate" the other failed drive?
All array member drives are fully used to simulate the failed drive. That is why it's so crucial for a new drive to be all zeros, or for parity to be recalced using the existing values.

 

Quick parity tutorial. So quick it's missing crucial technical detail, but here goes. Say you have 3 drives, so 2 data and 1 parity.

 

At location address 1 on all the drives, the 2 data drives have 0, so the parity is set to 1, to make the total = 1. Location 2, 1st data is 0 second is 1, so parity is set to 0 so the total = 1. Location 3, D1=1, D2=1, so parity is set to 1 for a total of 1. Using the other two drives, any location can be calculated. Adding a 4th drive, you either need to do all the math again, or you can make sure all the locations are 0, so parity is still the same as it was before you added the drive. Once again, if you remove one of the other drives, you can use the other drives to calculate the value that should be there. If a location that is assumed to be 0 is actually 1, then the simulated data is going to be wrong at that location.

When you add a precleared drive (or unRaid clears it), then unRaid knows that the new drive has all 0's, and therefore no parity computations are required since X+0=X....parity does not change.

Understood

 

But, when a drive fails, it is simulated by unRaid by taking the 1s & 0s of all the data drives plus parity drive to figure out what the bit should/would be on the failed drive.

Something is missing here,

1) Let go with the drive was cleared and not used, all 0's right, how do all these zero help simulate a failed drive.

2) Let go with the drive was faked thus has 0/1, how are the 0/1's to this particular drive helpfully to simulate a failed drive?

I don't get why it would use anything (0/1) from this new drive to "simulate" the other failed drive?
All array member drives are fully used to simulate the failed drive. That is why it's so crucial for a new drive to be all zeros, or for parity to be recalced using the existing values.

 

Quick parity tutorial. So quick it's missing crucial technical detail, but here goes. Say you have 3 drives, so 2 data and 1 parity.

 

At location address 1 on all the drives, the 2 data drives have 0, so the parity is set to 1, to make the total = 1. Location 2, 1st data is 0 second is 1, so parity is set to 0 so the total = 1. Location 3, D1=1, D2=1, so parity is set to 1 for a total of 1. Using the other two drives, any location can be calculated. Adding a 4th drive, you either need to do all the math again, or you can make sure all the locations are 0, so parity is still the same as it was before you added the drive. Once again, if you remove one of the other drives, you can use the other drives to calculate the value that should be there. If a location that is assumed to be 0 is actually 1, then the simulated data is going to be wrong at that location.

 

SO its because this fake drives location address 1 = 1 instead of 0 (because it was not cleared) some how messes things up for data that is on another drive?

 

(Don't mean to drive anyone crazy, appreciate all the postings)

Lets do some examples basing on jonathanm's info

 

1 Parity = All drives plus Parity must = 1 (i.e. need odd number of 1s)

Since a precleared drive has all 0s, parity does not change and is not recalculated

 

Drives (original)

1  2  3  Parity

0  0  0  1

0  0  1  0

0  1  0  0

0  1  1  1

1  0  0  0

1  0  1  1

1  1  0  1

1  1  1  0

 

Drives (precleared drive added)

1  2  3  4  Parity

0  0  0  0  1

0  0  1  0  0

0  1  0  0  0

0  1  1  0  1

1  0  0  0  0

1  0  1  0  1

1  1  0  0  1

1  1  1  0  0

 

 

Drives (drive 3 fails)

1  2  4  Parity  Sim 3

0  0  0  1    = (0+0+0+1)=0

0  0  0  0    = (0+0+0+0)=1

0  1  0  0    = (0+1+0+0)=0

0  1  0  1    = (0+1+0+1)=1

1  0  0  0    = (1+0+0+0)=0

1  0  0  1    = (1+0+0+1)=1

1  1  0  1    = (1+1+0+1)=0

1  1  0  0    = (1+1+0+0)=1

 

 

Drives (faked precleared drive 4 added)

1  2  3  4  Parity

0  0  0  1  1

0  0  1  0  0

0  1  0  1  0

0  1  1  0  1

1  0  0  1  0

1  0  1  1  1

1  1  0  0  1

1  1  1  1  0

 

Drives (drive 3 fails with "fake cleared drive")

1  2  4  Parity  Sim 3

0  0  1  1    = (0+0+1+1)=1  (should have been 0)

0  0  0  0    = (0+0+0+0)=1

0  1  1  0    = (0+1+1+0)=1  (should have been 0)

0  1  0  1    = (0+1+0+1)=1

1  0  1  0    = (1+0+1+0)=1  (should have been 0)

1  0  1  1    = (1+0+1+1)=0  (should have been 1)

1  1  0  1    = (1+1+0+1)=0

1  1  1  0    = (1+1+1+0)=0  (should have been 1)

 

 

So if you had "faked" a pre-clear signature and the drive was not all 0s, then you can see that the simulated failed drive would not match what was originally on the failed drive (Drive 3 in my examples). That would be your file/data corruption.

 

Which is the drive that is fake? in  "Drives (faked precleared drive added)"

 

Which is the drive that is fake? in  "Drives (faked precleared drive added)"

 

Drives (faked precleared drive 4 added)

1  2  3  4  Parity

0  0  0  1  1

0  0  1  0  0

0  1  0  1  0

0  1  1  0  1

1  0  0  1  0

1  0  1  1  1

1  1  0  0  1

1  1  1  1  0

 

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.