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.

[SOLVED] Failure rebuilding data drive

Featured Replies

Im really new at unraid and just built my first unraid server.  Just for my own peace of mind, I would like to pull out a data drive, erase all data and then reinstall it and let parity rebuild the data on it. I would like to do this so I can see that it is reliable and i can trust unraid if disaster strikes.  Ive attempted this twice now, and both times after a lengthy 9 hour data rebuild from unraid, the drive ends up completely empty.  Im hoping someone can tell me what im dooing wrong. I followed the instructions in the wiki to replace a failed disk or upgrade to a larger disk which was:

  1. Stop the array.

  2. Power down the unit.

  3. Replace the failed hard disk with a new one.

  4. Power up the unit.

  5. Start the array.

Once I powered up the unraid unit after the formatted disk was connected,  I was given the option to format the disk i just reconnected so thats what I did. after the format I had to reassign the drive to the array.  Then I was given the option to start the array and rebuild data, so that was the option I also chose.  After approximately 9 hours  the array was finished the data rebuild so I explored the disk that I previously formatted but there were no files restored.

 

Did I miss a step somewhere? should I have unassigned the drive from the array  before I powered down?

I will include my syslog.txt and server build if it can help.

 

unRAID v4.7

WD20EARS - Parity

WD20EARS - Data

Hitachi Deskstar 7K2000 -Data

ASUS M4A78LT-M

AMD Athlon II X2 250

Crucial 4GB DDR3 1066

syslog.txt

Then I was given the option to start the array and rebuild data, so that was the option I also chose.
Are you sure that this option was not to rebuild parity?

 

unRAID does not format a replacement disk. A replacement disk should be added to the array in the same slot as the missing drive then the rebuild option will appear.

These messages look suspicious:

Mar 24 17:27:49 Tower kernel: attempt to access beyond end of device\

Mar 24 17:27:49 Tower kernel: sdb1: rw=0, want=3907028992, limit=3907026944\

Mar 24 17:27:49 Tower kernel: md: disk2 read error\

Mar 24 17:27:49 Tower kernel: handle_stripe read error: 3907028984/2, count: 1\

Mar 24 17:27:49 Tower kernel: attempt to access beyond end of device\

Mar 24 17:27:49 Tower kernel: sdb1: rw=1, want=3907028992, limit=3907026944\

Mar 24 17:27:49 Tower kernel: md: disk2 write error\

Mar 24 17:27:49 Tower kernel: handle_stripe write error: 3907028984/2, count: 1\

 

 

How are you "erasing all data" ??  (we need the EXACT command you used)

 

 

 

  • Author

How are you "erasing all data" ??  (we need the EXACT command you used)

 

My first attempt I removed the data drive and connected it to my ubuntu system via USB and used gparted to remove the partition.

On my second attempt i tried a telnet session with the unraid server and used the command "dd if=/dev/zero of=/dev/sdb bs=1M"  to zero the drive in hopes that unraid would see it as a brand new drive. that was also a rebuild failure.

my most recent attempt i used the preclear script and am now almost 18% into the data rebuild.  Although I dont have much faith because Ive seen the data rebuild attempt on the last two tries and when it was finished the hard drive was completely empty.

OK, once unRAID has "rebuilt" the disk once then it will rebuild it the same way over and over. You'll never get the data back by rebuilding if the last successful rebuild returned an empty disk.

 

So, once again what exact steps did you take between the drive failure and the replace drive being rebuild?

 

When you replace a failed drive you phyiscally remove the old one and connect the new one. If the interface does not show that the swapped drive is an upgrade/replacement then do not start. Go to the devices page and set the replaced slot to the new drive. Then, you should get an indication the data will be rebuild onto the new drive and there will be an "are you sure" check box you have to check before you can hit start. If you did something else then the rebuild could fail.

 

Still, those errors Joe pointed out are not good and have to be addressed.

 

Peter

 

  • Author

OK, once unRAID has "rebuilt" the disk once then it will rebuild it the same way over and over. You'll never get the data back by rebuilding if the last successful rebuild returned an empty disk.

 

Each time I had a failure to rebuild I started from scratch. I would remove all three drives from the case and connect them via usb to my ubuntu laptop and use gparted to remove the partitions. I would also reformat my sandisk usb and reinstall unRAID v4.7 basic.  After the unRAID server has started I assign 2 data disks to the array but leave the parity unassigned at the moment so it will be faster to do the initial transfer of aprox 2 terabytes of media to the server. after I start the array it show the drives must be formatted so accept and continue.  After the format I create my shares and copy my media from the laptop over ethernet to the unRAID server. Once the copy is complete i assign the parity disk, and let it build parity which seems to take about 9 hours.

 

So, once again what exact steps did you take between the drive failure and the replace drive being rebuild?

 

To simulate a drive failure I first check parity to make sure there are no errors.  I then stop the array, power off the system, remove a data drive and connect it via usb to my ubuntu laptop and use gparted to remove the partition.  Then I place the same harddrive back on the same sata connector in the server case and power up unRAID. from the menu I have the option 'Start will bring the array online, start data rebuild,and then expand the file system (if possible). and then a checkbox for im sure I want to do this. so that is what i select.  I then get and orange light beside my data drive and 'data rebuild in progress'. At the end of 8-9 hours the drive is empty.

 

When you replace a failed drive you phyiscally remove the old one and connect the new one. If the interface does not show that the swapped drive is an upgrade/replacement then do not start. Go to the devices page and set the replaced slot to the new drive. Then, you should get an indication the data will be rebuild onto the new drive and there will be an "are you sure" check box you have to check before you can hit start. If you did something else then the rebuild could fail.

 

I Do not connect a different drive, I am replacing it with the same drive that I have pulled the partition off.

I came across a post that may explain why I am having a problem http://lime-technology.com/forum/index.php?topic=5969.0

Because I am not changing the drive and replacing the same drive, unRAID is remembering the serial of the drive.  That post says I must unassigned the drive and restart the array so unRAID doesn't recognize the disk as previously being in the array.

 

I am going to start from scratch again and take notes on every step I take, and instead of using ubuntu to clear drives I am going to start with the preclear script for all three drives before setting up the array and also format and reinstall unraid server to my usb stick.

That sounds like you found a bug. Try again by starting the array without the drive assigned and then assign it and do the rebuild. If that works then I would report what you did to Limetech. The option to rebuild appearing and the rebuild process should not fail like that.

 

What did you do to clear the partition? Remove the MBR? Zero out the first part of the drive?

 

I don't think you need to clear everything fully to test it again. Just copy  some data to the drive and try a rebuild again. I bet you'll find your clearing method will always give you a blank disk unless you start with the disk unassigned one time.

 

Peter

 

How are you copying the data to the array? Using user shares or disk shares? Are you certain that the disk you're removing contains any data? Could the data be on the remaining data disk?

  • Author

How are you copying the data to the array? Using user shares or disk shares? Are you certain that the disk you're removing contains any data? Could the data be on the remaining data disk?

 

I copy using user shares but I have certain shares set up to use certain disks and verify by opening disk shares to see what is on each disk

  • Author

I finally successfully tested a parity restoration by manually erasing one of my data drives.  I believe the reason it worked this time was this piece of advice I found in a post

http://lime-technology.com/forum/index.php?topic=5969.msg56824#msg56824

 

unRAID will not automatically restore a failed disk, even if you plug it back in and it works perfectly.  You MUST replace a disk that fails with either a different disk, or make unRAID think it is a different disk by un-assigning it, starting the array with it un-assigned, and then re-assigning it. (It will forget the original model/serial number of the failed disk when you start the array with it un-assigned)

 

Joe L.

 

I think because I was not replacing the failed drive, instead I was re-inserting the same drive, It either didn't recognize there was a failure or It believed I wanted to add free space to the array instead of rebuilding data.

Could you access and use the server while this rebuild was occuring? If the answer is no then it was likely doing a drive clearing and not a rebuilding.

 

Peter

  • Author

Could you access and use the server while this rebuild was occuring? If the answer is no then it was likely doing a drive clearing and not a rebuilding.

 

Peter

 

Yes All the files that I previously had on that drive were still accessible after i un-assigned the drive and also while it was going through the rebuild stage once it was formatted and re-assigned.

 

SUCCESS!!!

 

I am confident now that unRAID will keep my backups safe.

 

Thanks for the help everyone.

What about during the failed attempts?

 

Peter

  • Author

What about during the failed attempts?

 

Peter

 

No, during the failed attempts the user shares disappeared during rebuild and disk share was empty. I thought once the rebuild was complete I would then be able to see the data on the drive, but that wasn't the case.

It was definately just clearing the drive those times then. It should have indicated it would clear the drive and add it to the storage pool, not rebuild the drive. If it did say it would rebuild the drive and then cleared it instead then that really should be reported to Limetech.

 

Peter

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.