diff options
Diffstat (limited to 'xlators/mgmt')
-rw-r--r-- | xlators/mgmt/glusterd/src/Makefile.am | 11 | ||||
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-hooks.c | 1 | ||||
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd.c | 2 | ||||
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd.h | 1 |
4 files changed, 7 insertions, 8 deletions
diff --git a/xlators/mgmt/glusterd/src/Makefile.am b/xlators/mgmt/glusterd/src/Makefile.am index d8a1e257c4e..913a2a70729 100644 --- a/xlators/mgmt/glusterd/src/Makefile.am +++ b/xlators/mgmt/glusterd/src/Makefile.am @@ -41,10 +41,9 @@ AM_LDFLAGS = -L$(xlatordir) CLEANFILES = install-data-hook: - -if GF_INSTALL_VAR_LIB_GLUSTERD - $(mkdir_p) $(localstatedir)/lib/ - (stat $(sysconfdir)/glusterd && \ - mv $(sysconfdir)/glusterd $(localstatedir)/lib/) || true; - (ln -sf $(localstatedir)/lib/glusterd $(sysconfdir)/glusterd) || true; +if GF_INSTALL_GLUSTERD_WORKDIR + $(mkdir_p) $(DESTDIR)$(GLUSTERD_WORKDIR) + (stat $(DESTDIR)$(sysconfdir)/glusterd && \ + mv $(DESTDIR)$(sysconfdir)/glusterd $(DESTDIR)$(GLUSTERD_WORKDIR)) || true; + (ln -sf $(DESTDIR)$(GLUSTERD_WORKDIR) $(sysconfdir)/glusterd) || true; endif diff --git a/xlators/mgmt/glusterd/src/glusterd-hooks.c b/xlators/mgmt/glusterd/src/glusterd-hooks.c index 2d402b0dd56..f36764e4832 100644 --- a/xlators/mgmt/glusterd/src/glusterd-hooks.c +++ b/xlators/mgmt/glusterd/src/glusterd-hooks.c @@ -260,6 +260,7 @@ glusterd_hooks_add_op_args (runner_t *runner, glusterd_op_t op, case GD_OP_SET_VOLUME: ret = glusterd_hooks_set_volume_args (op_ctx, runner); + glusterd_hooks_add_working_dir (runner, priv); break; case GD_OP_GSYNC_CREATE: diff --git a/xlators/mgmt/glusterd/src/glusterd.c b/xlators/mgmt/glusterd/src/glusterd.c index c5fa245dbd8..b59353566a7 100644 --- a/xlators/mgmt/glusterd/src/glusterd.c +++ b/xlators/mgmt/glusterd/src/glusterd.c @@ -1199,7 +1199,7 @@ init (xlator_t *this) first_time = 1; } - setenv ("GLUSTERD_WORKING_DIR", workdir, 1); + setenv ("GLUSTERD_WORKDIR", workdir, 1); gf_log (this->name, GF_LOG_INFO, "Using %s as working directory", workdir); diff --git a/xlators/mgmt/glusterd/src/glusterd.h b/xlators/mgmt/glusterd/src/glusterd.h index f7b4f012e03..f1139ad027d 100644 --- a/xlators/mgmt/glusterd/src/glusterd.h +++ b/xlators/mgmt/glusterd/src/glusterd.h @@ -464,7 +464,6 @@ enum glusterd_vol_comp_status_ { GLUSTERD_VOL_COMP_RJT, }; -#define GLUSTERD_DEFAULT_WORKDIR "/var/lib/glusterd" #define GLUSTERD_DEFAULT_PORT GF_DEFAULT_BASE_PORT #define GLUSTERD_INFO_FILE "glusterd.info" #define GLUSTERD_VOLUME_QUOTA_CONFIG "quota.conf" |