testdisk on a failed Linux md RAID10 member

How to use TestDisk to recover lost partition
Forum rules
When asking for technical support:
- Search for posts on the same topic before posting a new question.
- Give clear, specific information in the title of your post.
- Include as many details as you can, MOST POSTS WILL GET ONLY ONE OR TWO ANSWERS.
- Post a follow up with a "Thank you" or "This worked!"
- When you learn something, use that knowledge to HELP ANOTHER USER LATER.
Before posting, please read https://www.cgsecurity.org/testdisk.pdf
Locked
Message
Author
RobbieTheK
Posts: 1
Joined: 11 Jun 2020, 14:10

testdisk on a failed Linux md RAID10 member

#1 Post by RobbieTheK »

I had a 4 disk Linux software RAID10 and 2 disks failed. I have access to the drives and testdisk does find and identify them correctly.

I've seen some folks have been able to recover a failed RAID member albeit on Windows viewtopic.php?t=824.

Code: Select all

Disk /dev/sdc - 2000 GB / 1863 GiB - ST2000DM001-1ER164

Please select the partition table type, press Enter when done.
>[Intel  ] Intel/PC partition

Hint: Intel partition table type has been detected.

Disk /dev/sdc - 2000 GB / 1863 GiB - CHS 243201 255 63
Current partition structure:
     Partition                  Start        End    Size in sectors

 1 P Linux RAID               0  32 33 243201  80 63 3907027120 [ourserver :2]
No partition is bootable
quick search:

Code: Select all

Disk /dev/sdc - 2000 GB / 1863 GiB - CHS 243201 255 63
     Partition               Start        End    Size in sectors
>* Linux RAID               0  32 33 243184 252 12 3906764800 [ourserver :2]

Structure: Ok.  Use Up/Down Arrow keys to select partition.
Use Left/Right Arrow keys to CHANGE partition characteristics:
*=Primary bootable  P=Primary  L=Logical  E=Extended  D=Deleted
Keys A: add partition, L: load backup, T: change type,
     Enter: to continue
md 1.x L.Endian Raid 10 - Array Slot : 2 (0, empty, 2), 2000 GB / 1862 GiB
Deep search start:

Code: Select all

Disk /dev/sdc - 2000 GB / 1863 GiB - CHS 243201 255 63
Analyse cylinder   536/243200: 00%

432 33 243184 219 51 3906762760 [ourserver :2]
Is deep search the best way to find any recoverable files?

recuperation
Posts: 2729
Joined: 04 Jan 2019, 09:48
Location: Hannover, Deutschland (Germany, Allemagne)

Re: testdisk on a failed Linux md RAID10 member

#2 Post by recuperation »

I do not have experience with your Linux raid configuration.
I just looked up what "RAID 10" stands for in a wikipedia article.

When the content is striped over two drives you cannot recover stuff by just applying Testdisk onto one single drive.
You have to make sure to have two drives in action that both represent all stripes involved.

When using Raid 0 one drive is perfectly OK to run Testdisk on one out of two because there is no striping involved. All data is on each disk it is mirrored.

In your case one disk only contains half of the stripes.
I guess you would have to apply Testdisk on that logical device that is dividing access into individual stripes on both drives.
Such a device should show a total size of 4000GB in your case.

That's why I did not answer your question.

Locked