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.

Preclear drives with out unraid on windows

Featured Replies

Is there a way to pre-clear drives without using the pre-clear script on unraid?  I'm away from my unraid server and would like to pre-clear drives before I get back to it (out of town for a couple of weeks).  It would be really nice to plug a drive into my parents computer and pre-clear the drives so that when I get back home I can just add them to the array.  I have access to windows PC that I can not run linux on because my parents will still need to use the machine.

pre-clear will only run on linux. You can boot your parents machine with the free version of unRAID to pre-clear but it won't be available to them for the duration.

  • Author

The way that I understand it is that when you add a new drive to unraid it does not need to be pre-cleared if the drive is band new from the factory.

 

How does pre-clearing a drive work? does it just write all 0's or 1's?  What makes a drive pre-cleared?  Maybe there is a windows solution that isn't specific to unraid that may work?

 

If it just writes 0's or 1's maybe just a drive eraser will work.

The way that I understand it is that when you add a new drive to unraid it does not need to be pre-cleared if the drive is band new from the factory.

True, it does not need to be pre-cleared, but...

 

If being added to an existing parity protected array unRAID will clear the drive before presenting it to you for formatting.  During this clearing, the array will be off-line and unavailable for anything else.  This could be 5 or more hours with a large drive.  First time you have this happen when your family wants to watch a movie you''ll understand why pre-clearing is a good thing.

 

If a disk is brand new, it might suffer from an early failure, just when you are loading it with your precious data, or worse, when you overwrite the original source disk as you migrate disks to the unRAID server.  The preclear process is a burn-in process and weeds out many drives before thay are assigned in your array.  (reading on the forum, about 1 in 5 drives is defective when new...  do you feel lucky???)  Google "bathtub curve" for interesting reading.

How does pre-clearing a drive work? does it just write all 0's or 1's?

It first reads the entire drive.  This allows the SMART firmware on the disk to identify sectors it cannot read and mark them for re-allocation.  While reading it also reads random sectors testing the disks ability to seek from track to track reliably.  (It purposely puts the disk through a lot of random seeks from track to track, to force any marginal mechanical issues to show themselves.) Then, it writes zeros to the entire drive, allowing the SMART firmware to re-allocate sectors if needed, then it again reads the entire drive, this time verifying that zeros were written correctly...  Lastly, it writes a drive specific signature to the drive that unRAID will recognize.  This will allow unRAID to skip its own internal clearing of the drive, eliminating the lengthy down-time whie it clears a drive.
What makes a drive pre-cleared?  Maybe there is a windows solution that isn't specific to unraid that may work?
There is not.    No process will write the unRAID specific signature.  (although I'm sure you can find windows utilities to zero, and exercise the disk, unRAID will not recognize it as cleared.)  Unless you read it first, the un-readable sectors will not be discovered until you first attempt to read a file you loaded on your server.  In my opinion, that is not a good time to learn you cannot read a sector...  Especially if you've not yet installed a parity disk, as there is no way to then recover the sector.  (My advice, always install parity disk "BEFORE" adding your data to the array.)

If it just writes 0's or 1's maybe just a drive eraser will work.

Sorry, not that simple.

 

Joe L.

pre-clear will only run on linux. You can boot your parents machine with the free version of unRAID to pre-clear but it won't be available to them for the duration.

you can, but you must be VERY CAREFUL to not clear your parents disk in their PC.  There is no protection to ensure you will clear the correct disk.    When run in unRAID, it compares the disk device being cleared with those assigned to unRAID.  It will protect you from clearing a drive that is currently assigned to the array.

 

So, if you boot unRAID on another PC, make certain you match the model/serial number of the disk you wish cleared with those printed at the "Are you Sure?" prompt.  (You will feel really dumb if you clear the wrong drive after responding to the "are you sure" question with "Yes")

 

Joe L.

  • 5 months later...

Along these lines, can you pre-clear a drive using a Linux box (say, Mint, Puppy, etc) or does it need to boot exclusively to unRAID?

First, the best choice by far is to simply wait until you're home and do the preclear on your UnRAID system.  Note that you can run multiple sessions with a PreClear in each one -- so you can do several at a time [i think you can have up to 6 active sessions, although I've never cleared more than 4 drives at a time].

 

While it won't be a "preclear";  if you want to simply do a thorough test of the new drives to ensure they're good, you could install Western Digital's Data Lifeguard for Windows on your parents PC;  then connect your drives to it; and run Data Lifeguard. 

 

A good, quite thorough test is to do the following:  (a)  Run a Quick Test;  (b) Run the Extended Test;  © Write Zeroes (do the full write when prompted) to the disk;  (d) run another Quick Test; and (e) run another Extended Test.    If all of these complete error-free, you have a good drive that will almost certainly pass the PreClear error free.    It WILL still need to be either cleared by UnRAID or via PreClear, as it won't have the unique UnRAID signature on it.    But this will let you identify any bad drives you may have picked up.  Note that this complete set of tests will take a LONG time on a modern large capacity drive (you can probably  do one drive a day).

 

IMPORTANT:  As JoeL noted, be SURE you're doing this on your new drive(s), and not one of the drives already in the system.    Actually, the tests wouldn't hurt anything, but the Write Zeroes would obviously be a VERY BAD thing to do to the wrong drive !!  :)

I might be very risk adverse (and unlucky) ,  but after having 5 drives failing of a total of 14 in the last 2 years (and yes, they were brand new), i never put a drive in my array without at least 5 preclear cycles,  and that's when I'm in a hurry. I had my latest WD Green 2T running 10 cycles in a row (200hrs). This might be too much, but the way I see it, preclear is free (meaning you don't have to invest any time sitting down in front of your computer and worrying about data loss) but if your array fail,  the stress and time you will put into it, it's just not worthy.

 

My 2 cents

 

An over cautious guy ;)

Sent from my GT-I9100 using Tapatalk 2

 

 

If you want to get a start on burning in the drives on a Windows machine you can do what I generally do; use Western Digital's Data Lifeguard package:

 

http://support.wdc.com/product/download.asp?groupid=608&sid=3〈=en

 

this will work with other manufacturer's disks (I've used it on Seagate and Hitachi).  You do a "write zeroes" to the full disk and an "extended test" read of the full disk. Then use a Windows tool to check the SMART reports for any problems.  This will do part of what the preclear script does and give you a bit more rapid detection of marginal disks.  I typically do this with each new disk I purchase before I go to the bother of shutting down my unRAID server to install the drive for further testing (usually 2 preclear passes).

 

This process typically takes less than half the time that a single preclear pass takes, mainly because preclear intentionally:

 

1. does a read pass before writing anything

2. does a lot of seeking during the verify read pass.

 

which makes for a more through test.

 

But I have had a couple of drives fail the simple Western Digital test so find it worth while doing.

 

Regards,

 

Stephen

 

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.