Description of problem: When the gluster is compiled with -DDEBUG compiler flag, glusetr cli crashed upon running "gluster v heal <VOLNAME> info' Version-Release number of selected component (if applicable): 3.4.0.59rhs How reproducible: Hit twice in as many tries Steps to Reproduce: 1. Compile glusterfs with -DDEBUG and install 2. Run gluster v heal <VOLNAME> info' Actual results: [root@spitfire ]# gluster v heal master info glfsheal: mem-pool.c:63: gf_mem_set_acct_info: Assertion `type <= xl->mem_acct.num_types' failed. Expected results: There should be no crash Additional info: The backtrace from the core (gdb) bt #0 0x0000003b3a0328e5 in raise () from /lib64/libc.so.6 #1 0x0000003b3a0340c5 in abort () from /lib64/libc.so.6 #2 0x0000003b3a02ba0e in __assert_fail_base () from /lib64/libc.so.6 #3 0x0000003b3a02bad0 in __assert_fail () from /lib64/libc.so.6 #4 0x00007fa0a7312bc4 in gf_mem_set_acct_info (xl=0x7fa0a759f540, alloc_ptr=0x7fff2916b820, size=55, type=40) at mem-pool.c:63 #5 0x00007fa0a7312f4e in __gf_calloc (nmemb=1, size=55, type=40) at mem-pool.c:117 #6 0x00007fa0a72e1716 in gf_strdup (src=0x7fff2916b9d0 "spitfire.blr.redhat.com-4362-2014/02/10-09:16:33:12387") at mem-pool.h:140 #7 0x00007fa0a72ea60b in generate_glusterfs_ctx_id () at common-utils.c:2413 #8 0x00007fa0a6c12017 in glusterfs_ctx_defaults_init (ctx=0xc1e010) at glfs.c:72 #9 0x00007fa0a6c1342e in glfs_new (volname=0x7fff2916d39c "master") at glfs.c:432 #10 0x000000000040367a in main (argc=2, argv=0x7fff2916cfe8) at glfs-heal.c:429 (gdb) fr 4 #4 0x00007fa0a7312bc4 in gf_mem_set_acct_info (xl=0x7fa0a759f540, alloc_ptr=0x7fff2916b820, size=55, type=40) at mem-pool.c:63 63 GF_ASSERT (type <= xl->mem_acct.num_types); This is the supposed fix [root@skywalker rhs-glusterfs]# git diff diff --git a/api/src/glfs-mem-types.h b/api/src/glfs-mem-types.h index c2da4a9..3301b3d 100644 --- a/api/src/glfs-mem-types.h +++ b/api/src/glfs-mem-types.h @@ -16,7 +16,7 @@ #define GF_MEM_TYPE_START (gf_common_mt_end + 1) enum glfs_mem_types_ { - glfs_mt_glfs_t, + glfs_mt_glfs_t = GF_MEM_TYPE_START, glfs_mt_call_pool_t, glfs_mt_xlator_t, glfs_mt_glfs_fd_t,
Verified as fixed in glusterfs 3.7.1. Built glusterfs with debug option and ran `gluster volume heal info' command. Command works as expected, crash not observed.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHSA-2015-1495.html