From 644edb8e071b0dc78f9009ffbf6c80965c9b2b89 Mon Sep 17 00:00:00 2001 From: Stefan Priebe Date: Wed, 22 Aug 2018 08:33:04 +0200 Subject: [PATCH] mgr: balancer: deepcopy best plan - otherwise we get latest Fixes: http://tracker.ceph.com/issues/27000 Signed-off-by: Stefan Priebe (cherry picked from commit 9852b49dbb4be80b11e3f5fe172c6c9f7f3d4acd) --- src/pybind/mgr/balancer/module.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pybind/mgr/balancer/module.py b/src/pybind/mgr/balancer/module.py index ea602d09fb5a9..8f0ea5fc84a59 100644 --- a/src/pybind/mgr/balancer/module.py +++ b/src/pybind/mgr/balancer/module.py @@ -874,8 +874,8 @@ class Module(MgrModule): else: bad_steps = 0 best_pe = next_pe - best_ws = next_ws - best_ow = next_ow + best_ws = copy.deepcopy(next_ws) + best_ow = copy.deepcopy(next_ow) if best_pe.score == 0: break left -= 1 -- 2.39.5