diff options
author | Sanju Rakonde <srakonde@redhat.com> | 2019-04-26 22:28:53 +0530 |
---|---|---|
committer | Shyamsundar Ranganathan <srangana@redhat.com> | 2019-05-08 13:57:24 +0000 |
commit | 3fc7d08c1d5dd9ac9079ee60ea734342eafb42d0 (patch) | |
tree | ba549d0c06adf67d49729ba48bcc24470dd6accb /tests | |
parent | b2c6983d0c9eb980024743d8f9825bb4dcd44b6a (diff) |
glusterd: define dumpops in the xlator_api of glusterd
Problem: statedump is not capturing information related to glusterd
Solution: statdump is not capturing glusterd info because
trav->dumpops is null in gf_proc_dump_single_xlator_info ()
where trav is glusterd xlator object. trav->dumpops is null
because we missed to define dumpops in xlator_api of glusterd.
defining dumpops in xlator_api of glusterd fixes the issue.
fixes: bz#1703759
Change-Id: If85429ecb1ef580aced8d5b88d09fc15258bfc4c
Signed-off-by: Sanju Rakonde <srakonde@redhat.com>
(cherry picked from commit 5d866c13efdcdeddf184f012aa88a652e90ff22e)
Diffstat (limited to 'tests')
-rw-r--r-- | tests/bugs/glusterd/optimized-basic-testcases.t | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/bugs/glusterd/optimized-basic-testcases.t b/tests/bugs/glusterd/optimized-basic-testcases.t index dd98a65fa9a..d700b5ed5af 100644 --- a/tests/bugs/glusterd/optimized-basic-testcases.t +++ b/tests/bugs/glusterd/optimized-basic-testcases.t @@ -32,6 +32,16 @@ function get_brick_host_uuid() echo $host_uuid_list | awk '{print $1}' } +function generate_statedump_and_check_for_glusterd_info { + pid=`pidof glusterd` + #remove old stale statedumps + cleanup_statedump $pid + kill -USR1 $pid + #Wait till the statedump is generated + sleep 1 + fname=$(ls $statedumpdir | grep -E "\.$pid\.dump\.") + cat $statedumpdir/$fname | grep "xlator.glusterd.priv" | wc -l +} cleanup; @@ -279,4 +289,7 @@ mkdir -p /xyz/var/lib/glusterd/abc TEST $CLI volume create "test" $H0:/xyz/var/lib/glusterd/abc EXPECT 'Created' volinfo_field "test" 'Status'; +EXPECT "1" generate_statedump_and_check_for_glusterd_info + +cleanup_statedump `pidof glusterd` cleanup |