Jump to content
Ong Hui Hoong

[SOLVED] Wrongly Assigned Data Disk As Parity Disk

41 posts in this topic Last Reply

Recommended Posts

Hi All,

 

i have make a mistake to swap 1 of my data disk with my parity disk, i notice the mistake and stop the array immediately.

but the data drive has been corrupted as cannot be detected, but my parity disk i believe still intact.

 

is there anyway i can rebuild back my data drive using the parity drive?

i have click the new config, i have add back all the drive to the correct location (except corrupted Data disk i did not add in yet)

i start the array with parity is valid option and did not add the corrupted data disk and start array.

but all my folder in the corrupted data disk still missing.

is there anyway for me to emulate the corrupted disk?

since actually all my data still consider there, i just have to use the parity and my other data drive to rebuild back my corrupted disk.

Share this post


Link to post

oh ya this happen because my boot drive die, i have to start the array in new config.

which is y i added in the disk :(

very worry now, all my critical data was on that disk.

i have my party drive assign correctly now, all my data drive assign correctly also.

 

i need a solution to rebuild the corrupted data drive back from the parity and my other data drive.

 

i still in panic mode now :(

Share this post


Link to post

Hi,

 

If you have all but one disk and the parity is good, the array should be recoverable.

 

Best advice, leave it well alone until one of the experts drops in with some guidance or you are very likely to lose some data.

It can take a day or so to get support depending on time zones etc.


Good luck. 

Share this post


Link to post
1 hour ago, Decto said:

leave it well alone

Might even be a good idea to shutdown until further advice arrives.

 

I have some ideas but would rather wait on @JorgeB

Share this post


Link to post

 

1 hour ago, trurl said:

Might even be a good idea to shutdown until further advice arrives.

 

I have some ideas but would rather wait on @JorgeB

the server is now up but array not started. so all HDD is 'not in use' per say

Share this post


Link to post
2 hours ago, Decto said:

Hi,

 

If you have all but one disk and the parity is good, the array should be recoverable.

 

Best advice, leave it well alone until one of the experts drops in with some guidance or you are very likely to lose some data.

It can take a day or so to get support depending on time zones etc.


Good luck. 

yea something like that, if can recover 95% i will be happy already.

Share this post


Link to post

You can try the invalid slot command, but since it looks like you started the array twice with a different config parity won't be 100% in sync, so some corruption is expected, if you're using xfs it should be recoverable with small to none data loss, before posting the instructions I need to know what Unraid release you're using, also confirm that you only have one parity disk and the number of the disk you want to rebuild.

Share this post


Link to post
6 hours ago, JorgeB said:

You can try the invalid slot command, but since it looks like you started the array twice with a different config parity won't be 100% in sync, so some corruption is expected, if you're using xfs it should be recoverable with small to none data loss, before posting the instructions I need to know what Unraid release you're using, also confirm that you only have one parity disk and the number of the disk you want to rebuild.

yes im using default xfs,

using latest stable 6.8.3 version.

and is single parity array, with 6 ( 5 ok + 1 corrupted drive)

and only 1 data drive needed to be rebuild.

 

this should be the correct order of the HDD, the corrupted drive should be in slot 1 which i have not assign in yet.

image.png.a912411790dee29231e6a9e95a5c1cc0.png

 

do let me know the step by step that i need to bring up the corrupted drive.

Edited by Ong Hui Hoong

Share this post


Link to post

Follow the instructions below carefully and ask if there's any doubt.

 

-Tools -> New Config -> Retain current configuration: All -> Apply
-Check all assignments and assign any missing disk(s) if needed, like old disk1
-Important - After checking the assignments leave the browser on that page, the "Main" page.

-Open an SSH session/use the console and type (don't copy/paste directly from the forum, as sometimes it can insert extra characters):

mdcmd set invalidslot 1 29

-Back on the GUI and without refreshing the page, just start the array, do not check the "parity is already valid" box (GUI will still show that data on parity disk(s) will be overwritten, this is normal as it doesn't account for the invalid slot command, but they won't be as long as the procedure was correctly done), disk1 will start rebuilding, disk should mount immediately (probably not in this case) but if it's unmountable don't format, wait for the rebuild to finish (or cancel it) and then run a filesystem check.

Share this post


Link to post
5 minutes ago, JorgeB said:

Follow the instructions below carefully and ask if there's any doubt.

 

-Tools -> New Config -> Retain current configuration: All -> Apply
-Check all assignments and assign any missing disk(s) if needed, like old disk1
-Important - After checking the assignments leave the browser on that page, the "Main" page.

-Open an SSH session/use the console and type (don't copy/paste directly from the forum, as sometimes it can insert extra characters):


mdcmd set invalidslot 1 29

-Back on the GUI and without refreshing the page, just start the array, do not check the "parity is already valid" box (GUI will still show that data on parity disk(s) will be overwritten, this is normal as it doesn't account for the invalid slot command, but they won't be as long as the procedure was correctly done), disk1 will start rebuilding, disk should mount immediately (probably not in this case) but if it's unmountable don't format, wait for the rebuild to finish (or cancel it) and then run a filesystem check.

understand very clearly on the instruction, i will do it now, wish me luck #FingerCross ...

Share this post


Link to post
9 minutes ago, JorgeB said:

Follow the instructions below carefully and ask if there's any doubt.

 

-Tools -> New Config -> Retain current configuration: All -> Apply
-Check all assignments and assign any missing disk(s) if needed, like old disk1
-Important - After checking the assignments leave the browser on that page, the "Main" page.

-Open an SSH session/use the console and type (don't copy/paste directly from the forum, as sometimes it can insert extra characters):


mdcmd set invalidslot 1 29

-Back on the GUI and without refreshing the page, just start the array, do not check the "parity is already valid" box (GUI will still show that data on parity disk(s) will be overwritten, this is normal as it doesn't account for the invalid slot command, but they won't be as long as the procedure was correctly done), disk1 will start rebuilding, disk should mount immediately (probably not in this case) but if it's unmountable don't format, wait for the rebuild to finish (or cancel it) and then run a filesystem check.

anyway, before i start, 1 question, can i start the array without the disk1?

can i emulate the disk1 to confirm the data is there? then 2nd round only i add in the corrupted disk1 for rebuild?

Share this post


Link to post
2 minutes ago, Ong Hui Hoong said:

anyway, before i start, 1 question, can i start the array without the disk1?

No, but you can use a spare disk if available, same size or larger.

Share this post


Link to post
2 minutes ago, JorgeB said:

No, but you can use a spare disk if available, same size or larger.

ah, too bad then, let me follow ur instruction and start the array now ...

Share this post


Link to post
1 minute ago, JorgeB said:

Like mentioned disk1 will likely be unmountable because you mounted the array without all devices, you can cancel the rebuild and run xfs_repair to see if it's fixable, if yes then start rebuilding again:

https://wiki.unraid.net/Check_Disk_Filesystems#Checking_and_fixing_drives_in_the_webGui

 

 

should i stop now?

 

i start to panic already :(

 

image.thumb.png.b335306400ecdb1d3771b1085de3bff8.png

Share this post


Link to post

You can do it now, since not much point rebuilding if the filesystem can't be fixed, to use the GUI check you need to set the filesystem on that disk to xfs, you can do that by clicking on it.

Share this post


Link to post
4 minutes ago, JorgeB said:

You can do it now, since not much point rebuilding if the filesystem can't be fixed, to use the GUI check you need to set the filesystem on that disk to xfs, you can do that by clicking on it.

i have stop the array and change the files system to sfx. but it still show as unmounted, should i follow the xfs_repair repair 1st?

 

image.png.b7e2967095757383a8891006744cc6d4.png

Share this post


Link to post
1 minute ago, Ong Hui Hoong said:

i have stop the array and change the files system to sfx. but it still show as unmounted

Yes, that's expected, you have to run xfs_repair, using the GUI or the console.

Share this post


Link to post
2 minutes ago, JorgeB said:

Yes, that's expected, you have to run xfs_repair, using the GUI or the console.

ok i will do the repair now, i will update again.

Share this post


Link to post
8 minutes ago, Ong Hui Hoong said:

ok i will do the repair now, i will update again.

using GUI,

i have run the check with -n, then without any option. and now running with -L

Share this post


Link to post
2 minutes ago, Ong Hui Hoong said:

 

using GUI,

i have run the check with -n, then without any option. and now running with -L

afrer with -L, still same, and there is some read write on the parity, did i screw up? :(

 

image.thumb.png.6408ae00fd564b5a9324b8e5f972c6f0.png

 

 

Share this post


Link to post

Don't format, post the output of xfs_repair -vL

Share this post


Link to post
7 minutes ago, JorgeB said:

Don't format, post the output of xfs_repair -vL

should i do it with the parity disk in? it look like writing some data in to parity :(

Share this post


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.