ClusterSetParams: move vg-name checks from to CheckPrereq
authorHelga Velroyen <helgav@google.com>
Wed, 7 Aug 2013 15:52:38 +0000 (17:52 +0200)
committerHelga Velroyen <helgav@google.com>
Thu, 8 Aug 2013 15:48:47 +0000 (17:48 +0200)
commitc89eb67de10a11c29c181fad11c749305f8a8638
treed33bd04bc731871fe3c30e0bfe47096608ca2d7b
parent3f8567e145f4d7b09c3a884f55b2367565dead9a
ClusterSetParams: move vg-name checks from to CheckPrereq

This fixes a bug in the logic of 'gnt-cluster modify'.
Some checks that should better be done in 'CheckPrereq'
were actually done in 'Exec'. This lead to a strange
behavior in case the execution failed, because an
inconsistent state of the cluster's config was kept in
memory.

Signed-off-by: Helga Velroyen <helgav@google.com>
Reviewed-by: Thomas Thrainer <thomasth@google.com>
lib/cmdlib/cluster.py
test/py/ganeti.cmdlib.cluster_unittest.py