From fa1d2b24c5e4f0f5af8b70065c4195495ac5fd02 Mon Sep 17 00:00:00 2001 From: Kotresh HR Date: Wed, 16 Oct 2019 14:25:47 +0530 Subject: geo-rep: Fix config upgrade on non-participating node After upgrade, if the config files are of old format, it gets migrated to new format. Monitor process migrates it. Since monitor doesn't run on nodes where bricks are not hosted, it doesn't get migrated there. So this patch fixes the config upgrade on nodes which doesn't host bricks. This happens during config either on get/set/reset. Backport of: Patch: https://review.gluster.org/23555 Change-Id: Ibade2f2310b0f3affea21a3baa1ae0eb71162cba Signed-off-by: Kotresh HR BUG: 1762220 Change-Id: Ibade2f2310b0f3affea21a3baa1ae0eb71162cba fixes: bz#1764028 Signed-off-by: Kotresh HR --- geo-replication/syncdaemon/gsyncd.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'geo-replication') diff --git a/geo-replication/syncdaemon/gsyncd.py b/geo-replication/syncdaemon/gsyncd.py index 6ae5269542f..7b48d82ee97 100644 --- a/geo-replication/syncdaemon/gsyncd.py +++ b/geo-replication/syncdaemon/gsyncd.py @@ -255,7 +255,8 @@ def main(): if args.subcmd == "slave": override_from_args = True - if args.subcmd == "monitor": + if config_file is not None and \ + args.subcmd in ["monitor", "config-get", "config-set", "config-reset"]: ret = gconf.is_config_file_old(config_file, args.master, extra_tmpl_args["slavevol"]) if ret is not None: gconf.config_upgrade(config_file, ret) -- cgit