Commit 7f8ba25b authored by Petr Pudlak's avatar Petr Pudlak

Move configuration flush to a synchronized block

This ensures that the configuration is fully distributed and doesn't
change during the verification process.
Signed-off-by: default avatarPetr Pudlak <pudlak@google.com>
Reviewed-by: default avatarKlaus Aehlig <aehlig@google.com>
parent 191dff7f
...@@ -1866,9 +1866,6 @@ class LUClusterVerifyConfig(NoHooksLU, _VerifyErrors): ...@@ -1866,9 +1866,6 @@ class LUClusterVerifyConfig(NoHooksLU, _VerifyErrors):
self.bad = False self.bad = False
self._feedback_fn = feedback_fn self._feedback_fn = feedback_fn
# Force the configuration to be fully distributed before doing any tests
self.cfg.FlushConfig()
feedback_fn("* Verifying cluster config") feedback_fn("* Verifying cluster config")
for msg in self.cfg.VerifyConfig(): for msg in self.cfg.VerifyConfig():
...@@ -3450,6 +3447,8 @@ class LUClusterVerifyGroup(LogicalUnit, _VerifyErrors): ...@@ -3450,6 +3447,8 @@ class LUClusterVerifyGroup(LogicalUnit, _VerifyErrors):
with self.cfg.GetConfigManager(shared=True): with self.cfg.GetConfigManager(shared=True):
feedback_fn("* Gathering information about nodes (%s nodes)" % feedback_fn("* Gathering information about nodes (%s nodes)" %
len(self.my_node_uuids)) len(self.my_node_uuids))
# Force the configuration to be fully distributed before doing any tests
self.cfg.FlushConfig()
# Due to the way our RPC system works, exact response times cannot be # Due to the way our RPC system works, exact response times cannot be
# guaranteed (e.g. a broken node could run into a timeout). By keeping # guaranteed (e.g. a broken node could run into a timeout). By keeping
# the time before and after executing the request, we can at least have # the time before and after executing the request, we can at least have
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment