Re: Recover array after I panicked
From: Patrik Dahlström <hidden>
Date: 2017-04-25 11:37:53
2017-04-25 13:08 GMT+02:00, Andreas Klauer [off-list ref]:
On Tue, Apr 25, 2017 at 12:40:37PM +0200, Patrik Dahlström wrote:quoted
I was thinking if it was in fact a 5 disk raid + garbage from 1 disk, then the checksum would be correct if the garbage disk was filtered out. Does that make sens?No. With one disk missing there is no parity (no way to verify it).quoted
You mentioned something about linear device mapping before. What is that? Is it something I could experiment with? How do I do that?https://www.kernel.org/doc/Documentation/device-mapper/linear.txt Once you have found where data overlaps on both raids, you create a linear mapping of start..X of the 6disk raid, followed by X..end of the 5disk RAID. That way you get a device that holds your data intact as a whole, whereas the raid sets would give you the first half of data on the 6disk raid set (what was already reshaped) and the other half on the 5disk raid set (what had yet to be reshaped). This is only a way to get read access at the data, making the raid work as a standalone again (resume reshape with lost raid metadata) is another problem, to be tackled after you backed up your data ;)
I'm not sure how I would backup 20 TB of data. I'll backup what I can, of course. The most essential.
quoted
Output of examine calls:quoted
/dev/mapper/sda: Data Offset : 252928 sectorsquoted
/dev/mapper/sda-2: Data Offset : 252928 sectorsWrong. mdadm --grow changes the offset, so:
Oh, I see. Does it do that every time I grow? In that case the original 5disk raid won't have 128M offset either. The full history of this raid: 1. 2x6 TB + md0 (4x2 TB striped) <- data offset at 128M 2. replace md0 with 6 TB, rebuild data. Shouldn't change data offset since this is basically the same as replacing a faulty disk, right? 3. Grow to 4x6 TB <- data offset changed (unknown). 4. Grow to 5x6 TB <- data offset changed (unknown). 5. Grow to 6x6 TB <- data offset changed. This is when the problem started. Does the data offset change by a fixed or calculated value? Can I calculate the data offset by comparing to known data? I must say that you help has been most valuable. You have my eternal gratitude. Best regards // Patrik