Hide Forgot
core file present at /share/tickets/431/core.5122
This happened when we were testing glusterfs on our local cluster. ---------- Program terminated with signal 11, Segmentation fault. #0 client_start_ping (data=<value optimized out>) at client-protocol.c:490 490 dummy_frame->local = trans; (gdb) bt #0 client_start_ping (data=<value optimized out>) at client-protocol.c:490 #1 0x00002b4f2178faee in gf_timer_proc (ctx=0x19503010) at timer.c:172 #2 0x0000003384c06307 in start_thread () from /lib64/libpthread.so.0 #3 0x00000033844d1ded in clone () from /lib64/libc.so.6 (gdb) p *dummy_frame Cannot access memory at address 0x0 (gdb) bt #0 client_start_ping (data=<value optimized out>) at client-protocol.c:490 #1 0x00002b4f2178faee in gf_timer_proc (ctx=0x19503010) at timer.c:172 #2 0x0000003384c06307 in start_thread () from /lib64/libpthread.so.0 #3 0x00000033844d1ded in clone () from /lib64/libc.so.6 (gdb) l 485 486 hdrlen = gf_hdr_len (req, 0); 487 hdr = gf_hdr_new (req, 0); 488 489 dummy_frame = create_frame (this, this->ctx->pool); 490 dummy_frame->local = trans; 491 492 ret = protocol_client_xfer (dummy_frame, this, trans, 493 GF_OP_TYPE_MOP_REQUEST, GF_MOP_PING, 494 hdr, hdrlen, NULL, 0, NULL); (gdb) ------------------ Its completely possible that memory was exhausted and calloc would have returned NULL. Just need more checks at memory allocation place.
PATCH: http://patches.gluster.com/patch/2789 in master (protocol/client: add memory allocation checks)
PATCH: http://patches.gluster.com/patch/2789 in release-3.0 (protocol/client: add memory allocation checks)