diff options
| author | Shwetha K Acharya <sacharya@redhat.com> | 2019-05-29 16:49:01 +0530 |
|---|---|---|
| committer | Kotresh HR <khiremat@redhat.com> | 2019-11-06 22:29:14 +0530 |
| commit | 60eba49c6290d6f387986fdb41d37c613ad766b6 (patch) | |
| tree | a0ab8a824ce80ca5bfe742774b0d35ded4ec09da /geo-replication/syncdaemon/gsyncd.py | |
| parent | 3d702d34c94216f00ca3244eaa3ecabc34df7114 (diff) | |
geo-rep: Upgrading config file to new version
- configuration handling is enhanced with patch
https://review.gluster.org/#/c/glusterfs/+/18257/
- hence, the old configurations are not applied when
Geo-rep session is created in the old version and upgraded.
This patch solves the issue. It,
- checks if the config file is old.
- parses required values from old config file and stores in new
config file, which ensures that configerations are applied on
upgrade.
- stores old config file as backup.
- handles changes in options introduced in
https://review.gluster.org/#/c/glusterfs/+/18257/
Backport of:
> Patch: https://review.gluster.org/22894
> BUG: bz#1707731
> Change-Id: Iad8da6c1e1ae8ecf7c84dfdf8ea3ac6966d8a2a0
> Signed-off-by: Shwetha K Acharya <sacharya@redhat.com>
updates: bz#1764003
Change-Id: Iad8da6c1e1ae8ecf7c84dfdf8ea3ac6966d8a2a0
Signed-off-by: Kotresh HR <khiremat@redhat.com>
Diffstat (limited to 'geo-replication/syncdaemon/gsyncd.py')
| -rw-r--r-- | geo-replication/syncdaemon/gsyncd.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/geo-replication/syncdaemon/gsyncd.py b/geo-replication/syncdaemon/gsyncd.py index d528401e214..6ae5269542f 100644 --- a/geo-replication/syncdaemon/gsyncd.py +++ b/geo-replication/syncdaemon/gsyncd.py @@ -255,6 +255,11 @@ def main(): if args.subcmd == "slave": override_from_args = True + if args.subcmd == "monitor": + 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) + # Load Config file gconf.load(GLUSTERFS_CONFDIR + "/gsyncd.conf", config_file, |
