diff options
author | Raghavendra Bhat <raghavendra@redhat.com> | 2012-05-29 17:57:54 +0530 |
---|---|---|
committer | Vijay Bellur <vijay@gluster.com> | 2012-05-29 06:30:23 -0700 |
commit | 647f561f6ad16174da700ea6b70f01b6e0ae6d96 (patch) | |
tree | a7618d3a9a6c783a37688e068961dd2d874562c5 | |
parent | 9b9ede959d70438b1c41aad14ed189c03d16a544 (diff) |
glusterd: change working-directory from /etc/glusterd to /var/lib/glusterdv3.3.0qa44
as it is changed in RPM based install (using spec file), makes sense to do
it everywhere, even in source install
Change-Id: Id813104cf017ac575d4ce9bdff76b414c99db999
BUG: 824231
Signed-off-by: Raghavendra Bhat <raghavendra@redhat.com>
Reviewed-on: http://review.gluster.com/3479
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
-rw-r--r-- | configure.ac | 2 | ||||
-rw-r--r-- | doc/glusterd.vol | 2 | ||||
-rw-r--r-- | glusterfs.spec.in | 5 | ||||
-rwxr-xr-x | smoke.sh | 2 | ||||
-rw-r--r-- | xlators/mgmt/glusterd/src/Makefile.am | 8 |
5 files changed, 15 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac index 27a25088843..893a47f8e1d 100644 --- a/configure.ac +++ b/configure.ac @@ -533,6 +533,8 @@ AC_SUBST(INCLUDES) AM_CONDITIONAL([GF_DARWIN_HOST_OS], test "${GF_HOST_OS}" = "GF_DARWIN_HOST_OS") +AM_CONDITIONAL([GF_INSTALL_VAR_LIB_GLUSTERD], test ! -d /var/lib/glusterd && test -d /etc/glusterd ) + AC_OUTPUT echo diff --git a/doc/glusterd.vol b/doc/glusterd.vol index 809042cbdd9..de17d8fd8f9 100644 --- a/doc/glusterd.vol +++ b/doc/glusterd.vol @@ -1,6 +1,6 @@ volume management type mgmt/glusterd - option working-directory /etc/glusterd + option working-directory /var/lib/glusterd option transport-type socket,rdma option transport.socket.keepalive-time 10 option transport.socket.keepalive-interval 2 diff --git a/glusterfs.spec.in b/glusterfs.spec.in index 4a2320bff6c..c425e06401d 100644 --- a/glusterfs.spec.in +++ b/glusterfs.spec.in @@ -304,8 +304,9 @@ fi # Move legacy sysconf files to the correct sysconfdir if [ -d /etc/glusterd ]; then - cp -a /etc/glusterd /var/lib/ - mv /etc/glusterd /etc/glusterd.rpmsave + mkdir -p /var/lib + mv /etc/glusterd /var/lib/ + ln -sf /var/lib/glusterd /etc/glusterd fi if [ -d /var/lib/glusterd/vols ]; then @@ -14,7 +14,7 @@ function cleanup() killall -15 glusterfs glusterfsd glusterd glusterd 2>&1 || true; killall -9 glusterfs glusterfsd glusterd glusterd 2>&1 || true; umount -l $M 2>&1 || true; - rm -rf /etc/glusterd $P/export; + rm -rf /var/lib/glusterd /etc/glusterd $P/export; } function start_fs() diff --git a/xlators/mgmt/glusterd/src/Makefile.am b/xlators/mgmt/glusterd/src/Makefile.am index d1dbf584227..485350b3d1e 100644 --- a/xlators/mgmt/glusterd/src/Makefile.am +++ b/xlators/mgmt/glusterd/src/Makefile.am @@ -30,3 +30,11 @@ AM_CFLAGS = -fPIC -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -Wall -D$(GF_HOST_OS)\ CLEANFILES = + +install-data-hook: + +if GF_INSTALL_VAR_LIB_GLUSTERD + $(mkdir_p) /var/lib/ + (stat /etc/glusterd && mv /etc/glusterd /var/lib/) || true; + (ln -sf /var/lib/glusterd /etc/glusterd) || true; +endif |