From 634a14603c0583fadd67e09a4734fd6708f2fcdd Mon Sep 17 00:00:00 2001 From: Klaus Aehlig Date: Wed, 26 Jun 2013 14:51:24 +0200 Subject: [PATCH] Make hroller not consider offline nodes for evacuation When planing on where to evacuate the non-redundant instances of the nodes to be rebooted, it doesn't make sense to consider offline nodes. So add this restriction to hroller. Signed-off-by: Klaus Aehlig Reviewed-by: Michele Tartara --- src/Ganeti/HTools/Program/Hroller.hs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Ganeti/HTools/Program/Hroller.hs b/src/Ganeti/HTools/Program/Hroller.hs index 1887a86..1bd1099 100644 --- a/src/Ganeti/HTools/Program/Hroller.hs +++ b/src/Ganeti/HTools/Program/Hroller.hs @@ -252,7 +252,8 @@ main opts args = do colorings = map (\(v,a) -> (v,(colorVertMap.a) nodeGraph)) colorAlgorithms smallestColoring = IntMap.elems $ (snd . minimumBy (comparing (IntMap.size . snd))) colorings - allNdx = map Node.idx $ Container.elems nlf + allNdx = map Node.idx . filter (not . Node.offline) . Container.elems + $ nlf splitted = mapM (\ grp -> partitionNonRedundant grp allNdx (nlf,ilf)) smallestColoring rebootGroups <- if optIgnoreNonRedundant opts -- 1.7.10.4