summaryrefslogtreecommitdiffstats
path: root/tests/bugs/cli/bug-1047416.t
diff options
context:
space:
mode:
authorRichard Wareing <rwareing@fb.com>2014-02-12 18:37:55 -0800
committerJeff Darcy <jdarcy@redhat.com>2015-10-08 05:44:27 -0700
commit722ed512220395af8a707756b49df67afacda795 (patch)
treeae2e4cf59a5b7fb33ecb506eb823bb049b520a05 /tests/bugs/cli/bug-1047416.t
parentebe40c5047e7501a5bd1747cb4d62277ae0db6e9 (diff)
xlators: add JSON FOP statistics dumps every N seconds
Summary: - Adds a thread to the io-stats translator which dumps out statistics every N seconds where N is configurable by an option called "diagnostics.stats-dump-interval" - Thread cleanly starts/stops when translator is unloaded - Updates macros to use "Atomic Builtins" (e.g. intel CPU extentions) to use memory barries to update counters vs using locks. This should reduce overhead and prevent any deadlock bugs due to lock contention. Test Plan: - Test on development machine - Run prove -v tests/basic/stats-dump.t Change-Id: If071239d8fdc185e4e8fd527363cc042447a245d BUG: 1266476 Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.org/12209 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Avra Sengupta <asengupt@redhat.com>
Diffstat (limited to 'tests/bugs/cli/bug-1047416.t')
-rw-r--r--tests/bugs/cli/bug-1047416.t5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/bugs/cli/bug-1047416.t b/tests/bugs/cli/bug-1047416.t
index 6e1b0a48467..864301034c9 100644
--- a/tests/bugs/cli/bug-1047416.t
+++ b/tests/bugs/cli/bug-1047416.t
@@ -12,10 +12,15 @@ function write_to_file {
TEST glusterd
TEST pidof glusterd
TEST $CLI volume create $V0 replica 2 $H0:$B0/${V0}0 $H0:$B0/${V0}1
+# Increasing the json stats dump time interval, so that it doesn't mess with the test.
+TEST $CLI volume set $V0 diagnostics.stats-dump-interval 3600
TEST $CLI volume start $V0
TEST $CLI volume profile $V0 start
TEST glusterfs --volfile-id=/$V0 --volfile-server=$H0 $M0 --attribute-timeout=0 --entry-timeout=0
+# Clear the profile info uptill now.
+TEST $CLI volume profile $V0 info clear
+
# Verify 'volume profile info' prints both cumulative and incremental stats
write_to_file &
wait