diff --git a/htools/Ganeti/HTools/Loader.hs b/htools/Ganeti/HTools/Loader.hs index 9c6badf39bd86368ea43507fa1f196dcd858b9b9..7f8f551b9749d3ff6c042dc6140b64df4789382d 100644 --- a/htools/Ganeti/HTools/Loader.hs +++ b/htools/Ganeti/HTools/Loader.hs @@ -221,7 +221,10 @@ mergeData um extags selinsts exinsts cdata@(ClusterData _ nl il2 tags) = in if not $ all (`elem` all_inst_names) exinsts then Bad $ "Some of the excluded instances are unknown: " ++ show (exinsts \\ all_inst_names) - else Ok cdata { cdNodes = snl, cdInstances = sil } + else if not $ all (`elem` all_inst_names) selinsts + then Bad $ "Some of the selected instances are unknown: " ++ + show (selinsts \\ all_inst_names) + else Ok cdata { cdNodes = snl, cdInstances = sil } -- | Checks the cluster data for consistency. checkData :: Node.List -> Instance.List