On 5/19/2021 3:01 PM, antlists wrote:
On 19/05/2021 20:01, Leslie Rhorer wrote:
The ONLY time you can be reasonably confident that running --create WILL
recover a damaged array is if it is still in its original state - no
drives swapped, no admin changes to the array, AND you're using the same
version of mdadm.
That's a little bit of an overstatement, depending on what you
mean by "reasonably confident". Swapped drives should not ordinarily
cause an issue, especially with RAID 4 or 5. The parity is, after
all, numerically unique. Admin changes to the array should be
similarly fully established provided the rebuild completed properly.
I don't think the parity algorythms have changed over time in mdadm,
either. Had they done so, mdadm would not be able to assemble arrays
from previous versions regardless of whether the superblock was intact.
You said there's only three possible combinations of three drives. Every
change I've mentioned adds another variable - more options ...
I meant 6, not 3.
The data offset is not fixed, for one.
All of the data offsets were 262144 sectors in the listed Examine were
262144 sectors.
Swapping a drive could mean
drives have different offsets which means NO combination of drives
I think not. That is to say, it is certainly not impossible for it to
change, but it is quite unlikely. For one thing, if the offset is more,
then all the data will no longer fit on the device, which would be a bit
of a disaster.
My main arrays consist of 8 drives each. Every drive in both arrays
has been replaced numerous times, starting with 1T drives more than 10
years ago. Now they are all 8T drives. All 16 have data offsets of
262144 sectors, just like the report from his drives. Note I have seen
arrays with different offsets, and of course any array on a partition
will have a different offset.
So while it is possible the offsets on his drives have changed, it is
not at all likely. Again. likely or not, it will not hurt for him to try.
Yes you can explicitly specify everything, and get mdadm to recover the
array if the superblocks have been lost, but it's nowhere as simple as
"there are only three possible combinations".
The number of permutations of the order of three drives is precisely
six. The permutations are:
1, 2, 3
1, 3, 2
2, 1, 3
2, 3, 1
3, 1, 2
3, 2, 1
The Examine stated it was 2, 3, 1, but the device order is not at all
unlikely to have changed. Once again, I was very explicit in saying the
simple create may not work and if not he is facing some much more
serious issues. That was and is in no way incorrect. The odds one of
them will work are not terrible, and if so, he is in good shape. Are
you seriously implying there is no way any of them could possibly work?
Are you seriously suggesting he should not try the simple approach
before digging deep into the data to try to figure out all the
parameters when the system was shut down?