summaryrefslogtreecommitdiffstats
path: root/tests/bugs/replicate/bug-830665.t
diff options
context:
space:
mode:
authorRavishankar N <ravishankar@redhat.com>2017-06-15 15:36:07 +0530
committerPranith Kumar Karampuri <pkarampu@redhat.com>2017-06-19 05:16:53 +0000
commitb58a15948fb3fc37b6c0b70171482f50ed957f42 (patch)
treeb046fe37593ebeea35d5a71daf41e4210bd21843 /tests/bugs/replicate/bug-830665.t
parent26ca39ccf0caf0d55c88b05396883dd10ab66dc4 (diff)
index: Do not proceed with init if brick is not mounted
..or else when a volume start force is given, we end up creating /brick-path/.glusterfs/indices folder and various subdirs under it and eventually starting the brick process. As a part of this patch, glusterd_get_index_basepath() is added in glusterd, who will then use it to create the basepath during volume-create, add-brick, replace-brick and reset-brick. It also uses this function to set the 'index-base' xlator option for the index translator. Change-Id: Id018cf3cb6f1e2e35b5c4cf438d1e939025cb0fc BUG: 1457202 Signed-off-by: Ravishankar N <ravishankar@redhat.com> Reviewed-on: https://review.gluster.org/17426 Smoke: Gluster Build System <jenkins@build.gluster.org> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> CentOS-regression: Gluster Build System <jenkins@build.gluster.org> Reviewed-by: Atin Mukherjee <amukherj@redhat.com> Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Diffstat (limited to 'tests/bugs/replicate/bug-830665.t')
-rwxr-xr-xtests/bugs/replicate/bug-830665.t5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/bugs/replicate/bug-830665.t b/tests/bugs/replicate/bug-830665.t
index c748c1304bf..d044dae75ea 100755
--- a/tests/bugs/replicate/bug-830665.t
+++ b/tests/bugs/replicate/bug-830665.t
@@ -76,6 +76,11 @@ volid=$(getfattr -e hex -n trusted.glusterfs.volume-id $B0/${V0}-0 2> /dev/null
| grep = | cut -d= -f2)
rm -rf $B0/${V0}-0;
mkdir $B0/${V0}-0;
+#Ideally, disk replacement is done using reset-brick or replace-brick gluster CLI
+#which will create .glusterfs/indices folder.
+mkdir $B0/${V0}-0/.glusterfs && chmod 600 $B0/${V0}-0/.glusterfs
+mkdir $B0/${V0}-0/.glusterfs/indices && chmod 600 $B0/${V0}-0/.glusterfs/indices
+
setfattr -n trusted.glusterfs.volume-id -v $volid $B0/${V0}-0
## Restart and remount. Note that we use actimeo=0 so that the stat calls