[PATCH 4/4] Monitor: array that has disappeared doesn't need spares

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>From 4d1f9e34397a7e9f0af8a68025a9f9e76ead57c3 Mon Sep 17 00:00:00 2001
From: Anna Czarnowska <anna.czarnowska@xxxxxxxxx>
Date: Fri, 26 Nov 2010 15:31:15 +0100
Subject: [PATCH 4/4] Monitor: array that has disappeared doesn't need spares
Cc: linux-raid@xxxxxxxxxxxxxxx, Williams, Dan J <dan.j.williams@xxxxxxxxx>, Ciechanowski, Ed <ed.ciechanowski@xxxxxxxxx>

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@xxxxxxxxx>
---
 Monitor.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/Monitor.c b/Monitor.c
index b78a66b..0a7c25f 100644
--- a/Monitor.c
+++ b/Monitor.c
@@ -877,7 +877,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;
-- 
1.7.1

--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux