From 722ed512220395af8a707756b49df67afacda795 Mon Sep 17 00:00:00 2001 From: Richard Wareing Date: Wed, 12 Feb 2014 18:37:55 -0800 Subject: 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 Reviewed-on: http://review.gluster.org/12209 Tested-by: NetBSD Build System Tested-by: Gluster Build System Reviewed-by: Avra Sengupta --- xlators/debug/io-stats/src/Makefile.am | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'xlators/debug/io-stats/src/Makefile.am') diff --git a/xlators/debug/io-stats/src/Makefile.am b/xlators/debug/io-stats/src/Makefile.am index a55933b6d19..ecbc82061a7 100644 --- a/xlators/debug/io-stats/src/Makefile.am +++ b/xlators/debug/io-stats/src/Makefile.am @@ -11,7 +11,8 @@ noinst_HEADERS = io-stats-mem-types.h AM_CPPFLAGS = $(GF_CPPFLAGS) -I$(top_srcdir)/libglusterfs/src \ -I$(top_srcdir)/rpc/xdr/src \ - -I$(top_srcdir)/rpc/rpc-lib/src + -I$(top_srcdir)/rpc/rpc-lib/src \ + -DDATADIR=\"$(localstatedir)\" AM_CFLAGS = -Wall $(GF_CFLAGS) -- cgit