diff options
author | NeilBrown <neilb@suse.de> | 2010-02-04 12:02:09 +1100 |
---|---|---|
committer | NeilBrown <neilb@suse.de> | 2010-02-04 12:02:09 +1100 |
commit | 921d9e164fd3f6203d1b0cf2424b793043afd001 (patch) | |
tree | ad0fa1ec1343bd28676de6907177189ed14a748c /super-ddf.c | |
parent | cc86f89c855fcfe9820d0621ede1575adc317155 (diff) | |
download | mdadm-921d9e164fd3f6203d1b0cf2424b793043afd001.tar.gz mdadm-921d9e164fd3f6203d1b0cf2424b793043afd001.tar.xz mdadm-921d9e164fd3f6203d1b0cf2424b793043afd001.zip |
Assemble: fix --force assembly of v1.x arrays which are recovering.
1.x metadata allows a device to be a member of the array while it
is still recoverying. So it is a working member, but is not
completely in-sync.
mdadm/assemble does not understand this distinction and assumes that a
work member is fully in-sync for the purpose of determining if there
are enough in-sync devices for the array to be functional.
So collect the 'recovery_start' value from the metadata and use it in
assemble when determining how useful a given device is.
Reported-by: Mikael Abrahamsson <swmike@swm.pp.se>
Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'super-ddf.c')
-rw-r--r-- | super-ddf.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/super-ddf.c b/super-ddf.c index 3e30229..870efd8 100644 --- a/super-ddf.c +++ b/super-ddf.c @@ -1369,6 +1369,7 @@ static void getinfo_super_ddf(struct supertype *st, struct mdinfo *info) info->disk.state = (1 << MD_DISK_SYNC) | (1 << MD_DISK_ACTIVE); + info->recovery_start = MaxSector; info->reshape_active = 0; info->name[0] = 0; @@ -1427,6 +1428,7 @@ static void getinfo_super_ddf_bvd(struct supertype *st, struct mdinfo *info) info->container_member = ddf->currentconf->vcnum; + info->recovery_start = MaxSector; info->resync_start = 0; if (!(ddf->virt->entries[info->container_member].state & DDF_state_inconsistent) && |