Dan Williams: imsm: disambiguate family_num

Martin F. Krafft madduck at alioth.debian.org
Tue Oct 27 19:21:31 UTC 2009


Module: mdadm
Branch: master
Commit: a2b9798159755b6f5e867fae0dd3e25af59fc85e
URL:    http://git.debian.org/?p=pkg-mdadm/mdadm.git;a=commit;h=a2b9798159755b6f5e867fae0dd3e25af59fc85e

Author: Dan Williams <dan.j.williams at intel.com>
Date:   Wed Sep 30 11:45:41 2009 -0700

imsm: disambiguate family_num

This is a result of trawling through the Windows implementation to learn
the mechanism of how it disambiguates family_num.  It is a continuation
of commit 148acb7b "imsm: fix family number handling" which introduced a
regression when reassembling a container with stale disks and rebuilt
members.

When rebuilding, a new family number is assigned to protect against the
"prodigal array member" problem.  It prevents a former family member
from returning to the system and causing a rebuild to go the wrong
direction.  However, this invalidates looking at the generation number to
determine the most up-to-date disk when comparing across family numbers.
Instead the assembly logic looks for agreement between a disk's local
family membership compared against a global list of all families in the
system.  Whenever a disk's local metadata does not match a family number
on the global list that family number is marked offline.

It is possible that this logic results in multiple incompatible but
valid family numbers existing in a container.  In this case mdadm.conf
cannot be consulted because it only records the uuid which is generated
from static fields in the metadata.  The metadata lacks the data needed
to disambiguate "local" versus "foreign".  The "foreign" array in this
case requires updating to change its container-id information
(orig_family_num), and possibly the member array names.

Signed-off-by: Dan Williams <dan.j.williams at intel.com>


---

 super-intel.c |  580 ++++++++++++++++++++++++++++++++++++++++++++-------------
 1 files changed, 448 insertions(+), 132 deletions(-)

Diff:   http://git.debian.org/?p=pkg-mdadm/mdadm.git;a=commitdiff;h=a2b9798159755b6f5e867fae0dd3e25af59fc85e



More information about the pkg-mdadm-commits mailing list