summaryrefslogtreecommitdiffstats
path: root/tests/basic/quota-ancestry-building.t
diff options
context:
space:
mode:
authorvmallika <vmallika@redhat.com>2015-05-28 12:30:02 +0530
committerPranith Kumar Karampuri <pkarampu@redhat.com>2015-05-28 23:29:07 -0700
commitf6e72c45ad754073bc8269e954d236bab9e4a0e7 (patch)
treebd2ab7c55e85aab08cfbf6ccaa151ea1158e97ac /tests/basic/quota-ancestry-building.t
parente3408108e36dac08d217f558b5cc69dff71bbcbf (diff)
Quota: fix testcases not to send parallel writes for accurate
quota enforcement This is a backport of http://review.gluster.org/#/c/10878 > Currently quota enforcer doesn't consider parallel writes > and allows quota to exceed limit where there are high rate > of parallel writes. Bug# 1223658 tracks the issue. > > This patch fixes the spurious failures by not sending > parallel writes. > Using O_SYNC and O_APPEND flags and block size > not more that 256k (For higher block size NFS client > splits the block into 256k chinks and does parallel writes) > > Change-Id: I297c164b030cecb87ce5b494c02b09e8b073b276 > BUG: 1223798 > Signed-off-by: vmallika <vmallika@redhat.com> > Reviewed-on: http://review.gluster.org/10878 > Tested-by: NetBSD Build System > Tested-by: Gluster Build System <jenkins@build.gluster.com> > Reviewed-by: Raghavendra G <rgowdapp@redhat.com> > Tested-by: Raghavendra G <rgowdapp@redhat.com> Change-Id: I78b6250eb0b3fbbbab1d4348d4e81d6292c6c6bb BUG: 1224894 Signed-off-by: vmallika <vmallika@redhat.com> Reviewed-on: http://review.gluster.org/10910 Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: NetBSD Build System Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Diffstat (limited to 'tests/basic/quota-ancestry-building.t')
-rwxr-xr-xtests/basic/quota-ancestry-building.t8
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/basic/quota-ancestry-building.t b/tests/basic/quota-ancestry-building.t
index e86e1e250ee..5824db37879 100755
--- a/tests/basic/quota-ancestry-building.t
+++ b/tests/basic/quota-ancestry-building.t
@@ -8,6 +8,10 @@ cleanup;
# This tests quota enforcing on an inode without any path information.
# This should cover anon-fd type of workload as well.
+QDD=$(dirname $0)/quota
+# compile the test write program and run it
+build_tester $(dirname $0)/quota.c -o $QDD
+
TESTS_EXPECTED_IN_LOOP=8
TEST glusterd
TEST pidof glusterd
@@ -37,7 +41,7 @@ TEST fd_open 5 'w' "$M0/$deep/file3"
TEST fd_open 6 'w' "$M0/$deep/file4"
# consume all quota
-TEST ! dd if=/dev/zero of="$M0/$deep/file" bs=1000000 count=1
+TEST ! $QDD $M0/$deep/file 256 4
# simulate name-less lookups for re-open where the parent information is lost.
# Stopping and starting the bricks will trigger client re-open which happens on
@@ -62,4 +66,6 @@ exec 6>&-
TEST $CLI volume stop $V0
EXPECT "1" get_aux
+
+rm -f $QDD
cleanup;