summaryrefslogtreecommitdiffstats
path: root/tests/volume.rc
diff options
context:
space:
mode:
authorAshish Pandey <aspandey@redhat.com>2015-07-15 16:37:37 +0530
committerPranith Kumar Karampuri <pkarampu@redhat.com>2015-08-29 03:31:58 -0700
commit44e58a9385b0661c7015b317669c01c699ee9a3e (patch)
treeed97f503939d1ff5ab5fe67510e220cdb6b38443 /tests/volume.rc
parentfd47635a4ffab621a2357c99cd1edd0482940bd5 (diff)
ec : trusted.ec.version xattr of all root directories of all bricks should be same.
Problem: After replacing the brick using "replace-brick" command and running "heal full", the version of the root directory of the newly added brick is not getting healed. heal starts running on the dentries of the root but does not run on root directory. Solution: Run heal on root directory. Change-Id: Ifd42a3fb341b049c895817e892e5b484a5aa6f80 BUG: 1243382 Signed-off-by: Ashish Pandey <aspandey@redhat.com> Reviewed-on: http://review.gluster.org/11676 Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org>
Diffstat (limited to 'tests/volume.rc')
-rw-r--r--tests/volume.rc20
1 files changed, 17 insertions, 3 deletions
diff --git a/tests/volume.rc b/tests/volume.rc
index a100bde55ae..11ef9939d4d 100644
--- a/tests/volume.rc
+++ b/tests/volume.rc
@@ -121,7 +121,7 @@ function ec_get_info {
local vol=$1
local dist_id=$2
local key=$3
- local fpath=$(generate_mount_statedump $vol)
+ local fpath=$4
local value=$(sed -n "/^\[cluster\/disperse\.$vol-disperse-$dist_id\]/,/^\[/{s/^$key=\(.*\)/\1/p;}" $fpath | head -1)
rm -f $fpath
echo "$value"
@@ -131,14 +131,28 @@ function ec_child_up_status {
local vol=$1
local dist_id=$2
local brick_id=$(($3 + 1))
- local mask=$(ec_get_info $vol $dist_id "childs_up_mask")
+ local mask=$(ec_get_info $vol $dist_id "childs_up_mask" $(generate_mount_statedump $vol))
echo "${mask: -$brick_id:1}"
}
function ec_child_up_count {
local vol=$1
local dist_id=$2
- ec_get_info $vol $dist_id "childs_up"
+ ec_get_info $vol $dist_id "childs_up" $(generate_mount_statedump $vol)
+}
+
+function ec_child_up_status_shd {
+ local vol=$1
+ local dist_id=$2
+ local brick_id=$(($3 + 1))
+ local mask=$(ec_get_info $vol $dist_id "childs_up_mask" $(generate_shd_statedump $vol))
+ echo "${mask: -$brick_id:1}"
+}
+
+function ec_child_up_count_shd {
+ local vol=$1
+ local dist_id=$2
+ ec_get_info $vol $dist_id "childs_up" $(generate_shd_statedump $vol)
}
function get_shd_process_pid {