summaryrefslogtreecommitdiffstats
path: root/Monitor.c
diff options
context:
space:
mode:
authorAnna Czarnowska <anna.czarnowska@intel.com>2010-11-26 14:31:15 +0100
committerNeilBrown <neilb@suse.de>2010-11-28 23:58:22 +0100
commitef15641fb54b45255c167c8b02ea0ed47496b85d (patch)
tree62da0c0584be60b13c7272d3f6797f6fa56b75cc /Monitor.c
parentMonitor: fix writing autorebuild.pid (diff)
downloadmdadm-ef15641fb54b45255c167c8b02ea0ed47496b85d.tar.xz
mdadm-ef15641fb54b45255c167c8b02ea0ed47496b85d.zip
Monitor: array that has disappeared doesn't need spares
If a degraded array disappears we still have it in statelist with active<raid but it is pointless to look for spares for it. Signed-off-by: Anna Czarnowska <anna.czarnowska@intel.com> Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'Monitor.c')
-rw-r--r--Monitor.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Monitor.c b/Monitor.c
index 0e916884..d5514e9c 100644
--- a/Monitor.c
+++ b/Monitor.c
@@ -879,7 +879,7 @@ static void try_spare_migration(struct state *statelist, struct alert_info *info
link_containers_with_subarrays(statelist);
for (st = statelist; st; st = st->next)
if (st->active < st->raid &&
- st->spare == 0) {
+ st->spare == 0 && !st->err) {
struct domainlist *domlist = NULL;
int d;
struct state *to = st;