summaryrefslogtreecommitdiffstats
path: root/tests/volume.rc
diff options
context:
space:
mode:
authorVenky Shankar <vshankar@redhat.com>2015-12-30 14:56:12 +0530
committerPranith Kumar Karampuri <pkarampu@redhat.com>2016-01-26 18:44:58 -0800
commit0bfb02e3b56abf411882f245655921a91df885ef (patch)
tree21645b10808db0cac0072a0282dc8febbdb6f0aa /tests/volume.rc
parent30e4d0db013ece366c5036b1d82c0150f082128a (diff)
features/bitrot: add check for corrupted object in f{stat}
Backport of http://review.gluster.org/13120 Check for corrupted objects is done bt bitrot stub component for data operations and such fops are denied processing by returning EIO. These checks were not done for operations such as get/set extended attribute, stat and the likes - IOW, stub only blocked pure data operations. However, its necessary to have these checks for certain other fops, most importantly stat (and fstat). This is due to the fact that clients could possibly get stale stat information (such as size, {a,c,m}time) resulting in incorrect operation of the application that rely on these fields. Note that, the data that replication would take care of fetching good (and correct) data, but the staleness of stat information could lead to data inconsistencies (e.g., rebalance, tier). Change-Id: I5a22780373b182a13f8d2c4ca6b7d9aa0ffbfca3 BUG: 1297213 Signed-off-by: Venky Shankar <vshankar@redhat.com> Reviewed-on: http://review.gluster.org/13276 Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com> Tested-by: Pranith Kumar Karampuri <pkarampu@redhat.com> Smoke: Gluster Build System <jenkins@build.gluster.com> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> CentOS-regression: Gluster Build System <jenkins@build.gluster.com>
Diffstat (limited to 'tests/volume.rc')
-rw-r--r--tests/volume.rc8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/volume.rc b/tests/volume.rc
index 15037059deb..8724c08d249 100644
--- a/tests/volume.rc
+++ b/tests/volume.rc
@@ -19,6 +19,14 @@ function online_brick_count ()
pgrep glusterfsd | wc -l
}
+function brick_up_status {
+ local vol=$1
+ local host=$2
+ local brick=$3
+ brick_pid=$(get_brick_pid $vol $host $brick)
+ gluster volume status | grep $brick_pid | awk '{print $4}'
+}
+
function volume_option()
{
local vol=$1