From b65a9230a359de82cb4b5b2e802a493b72d46c4f Mon Sep 17 00:00:00 2001 From: Tony Asleson Date: Wed, 15 Mar 2017 14:19:55 -0500 Subject: [PATCH] lvmdbusd: Update state during pv move Periodically update the state during pv move so that all the different dbus objects reflect something close to reality during the process. --- daemons/lvmdbusd/background.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/daemons/lvmdbusd/background.py b/daemons/lvmdbusd/background.py index e870c0529..f7f77d586 100644 --- a/daemons/lvmdbusd/background.py +++ b/daemons/lvmdbusd/background.py @@ -64,6 +64,10 @@ def _move_merge(interface_name, command, job_state): (device, ignore, percentage) = line_str.split(':') job_state.Percent = round( float(percentage.strip()[:-1]), 1) + + # While the move is in progress we need to periodically update + # the state to reflect where everything is at. + cfg.load() except ValueError: log_error("Trying to parse percentage which failed for %s" % line_str) -- 2.43.5