Bug 763227 (GLUSTER-1495)

Summary: Volume create with stripe crashes
Product: [Community] GlusterFS Reporter: shishir gowda <sgowda>
Component: glusterdAssignee: Pavan Vilas Sondur <pavan>
Severity: high Docs Contact:
Priority: low    
Version: mainlineCC: gluster-bugs, nsathyan
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description shishir gowda 2010-09-01 03:12:56 EDT
When stripe count is given as 2 and 4 bricks are passed, glusterd crashes

Please find the back trace below:

(gdb) bt
#0  0x00007facfb80d35e in vfprintf () from /lib/libc.so.6
#1  0x00007facfb814498 in fprintf () from /lib/libc.so.6
#2  0x00007facfa094ead in __write_stripe_xlator (file=0x239fa00, dict=0x2381178, subvolume=0x7fffe6cedf50 "new-client", 
    stripe_count=2, count=1) at glusterd-volgen.c:886
#3  0x00007facfa096378 in generate_client_volfile (volinfo=0x23843d8, filename=0x239e9e8 "/etc/glusterd/vols/new/new-fuse.vol")
    at glusterd-volgen.c:1440
#4  0x00007facfa096feb in generate_client_volfiles (volinfo=0x23843d8) at glusterd-volgen.c:1637
#5  0x00007facfa0970e3 in glusterd_create_volfiles (volinfo=0x23843d8) at glusterd-volgen.c:1664
#6  0x00007facfa07cbc0 in glusterd_op_create_volume (req=0x2393c18) at glusterd-op-sm.c:1020
#7  0x00007facfa083550 in glusterd_op_commit_perform (req=0x2393c18) at glusterd-op-sm.c:3089
#8  0x00007facfa08c02b in glusterd3_1_commit_op (frame=0x0, this=0x23757e8, data=0x0) at glusterd3_1-mops.c:1056
#9  0x00007facfa082655 in glusterd_op_ac_send_commit_op (event=0x2395b48, ctx=0x0) at glusterd-op-sm.c:2687
#10 0x00007facfa083935 in glusterd_op_sm () at glusterd-op-sm.c:3339
#11 0x00007facfa08c597 in glusterd_handle_rpc_msg (req=0x7facfc777038) at glusterd3_1-mops.c:1223
#12 0x00007facfc18c5d3 in rpcsvc_handle_rpc_call (svc=0x2371658, trans=0x237b078, msg=0x2378c18) at rpcsvc.c:990
#13 0x00007facfc18c979 in rpcsvc_notify (trans=0x237b078, mydata=0x2371658, event=RPC_TRANSPORT_MSG_RECEIVED, data=0x2378c18)
    at rpcsvc.c:1085
#14 0x00007facfc1929c4 in rpc_transport_notify (this=0x237b078, event=RPC_TRANSPORT_MSG_RECEIVED, data=0x2378c18)
    at rpc-transport.c:1124
#15 0x00007facf9e4d9b9 in socket_event_poll_in (this=0x237b078) at socket.c:1561
#16 0x00007facf9e4dd6c in socket_event_handler (fd=5, idx=1, data=0x237b078, poll_in=1, poll_out=0, poll_err=0) at socket.c:1675
#17 0x00007facfc3df74f in event_dispatch_epoll_handler (event_pool=0x2370b18, events=0x237a448, i=0) at event.c:812
#18 0x00007facfc3df95f in event_dispatch_epoll (event_pool=0x2370b18) at event.c:876
#19 0x00007facfc3dfcc7 in event_dispatch (event_pool=0x2370b18) at event.c:984
#20 0x00000000004064ff in main (argc=2, argv=0x7fffe6ceef18) at glusterfsd.c:1398

(gdb) f 2
#2  0x00007facfa094ead in __write_stripe_xlator (file=0x239fa00, dict=0x2381178, subvolume=0x7fffe6cedf50 "new-client", 
    stripe_count=2, count=1) at glusterd-volgen.c:886
886	        fprintf (file, stripe_str,
(gdb) l
881	        for (i = 0; i < stripe_count; i++) {
882	                snprintf (tmp, 4096, "%s-%d ", subvolume, i);
883	                strncat (subvol_str, tmp, strlen (tmp));
884	        }
886	        fprintf (file, stripe_str,
887	                 volname,
888	                 count,
889	                 "stripe",
890	                 opt_blocksize,
891	                 opt_usexattr,
892	                 subvol_str);
895	        ret = 0;
897	out:
898	        return ret;
899	}
(gdb) p stripe_str
$7 = 0x7facfa09e798 "volume %s-%s-%d\ntype cluster/stripe\n#option block-size %s\n#option use-xattr %s\nsubvolumes %s\nend-volume\n\n"
Comment 1 shishir gowda 2010-09-01 23:16:40 EDT

*** This bug has been marked as a duplicate of bug 1497 ***