Bug #32951 stack badness in ndb
Submitted: 4 Dec 2007 8:04 Modified: 13 May 2008 8:45
Reporter: Tatiana Azundris Nuernberg Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Cluster: Cluster (NDB) storage engine Severity:S3 (Non-critical)
Version:6.0 OS:Any
Assigned to: CPU Architecture:Any

[4 Dec 2007 8:04] Tatiana Azundris Nuernberg
Description:
tests fail with broken stack, corruption seems to appear in or below
NdbOperation::setVarValue in NdbOperationDefine.cpp

#6  0x089ddfc4 in __stack_chk_fail_local ()
#7  0x08840d4b in NdbOperation::setValue (this=0x8e7ef20, tAttrInfo=0x8e85180, 
    aValuePassed=0xb6b95bc0 "@\037lcrwtfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoez
vahdbnfqyzgtqxalcrwtfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxalcrw
tfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxalcrwtfsqabknvtf"...)
    at NdbOperationDefine.cpp:621
#8  0x08840e9a in NdbOperation::setVarValue (this=0x8e7ef20, 
    tAttrInfo=0x8e85180, 
    aBareValue=0x8eb8be0 "lcrwtfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfq
yzgtqxalcrwtfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxalcrwtfsqabkn
vtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxalcrwtfsqabknvtfcb"..., 
    aLen=@0x8e7b230) at NdbOperationDefine.cpp:859
#9  0x08897ef6 in NdbBlob::setPartDataValue (this=0x8e7b150, anOp=0x8e7ef20, 
    buf=0x8eb8be0 "lcrwtfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxa
lcrwtfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxalcrwtfsqabknvtfcbpo
onxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxalcrwtfsqabknvtfcb"..., 
    aLen=@0x8e7b230) at NdbBlob.cpp:960
---Type <return> to continue, or q <return> to quit---
#10 0x0889aae1 in NdbBlob::insertPart (this=0x8e7b150, 
    buf=0x8eb8be0 "lcrwtfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxa
lcrwtfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxalcrwtfsqabknvtfcbpo
onxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxalcrwtfsqabknvtfcb"..., part=0, 
    len=@0x8e7b230) at NdbBlob.cpp:1686
#11 0x0889acff in NdbBlob::insertParts (this=0x8e7b150, 
    buf=0x8eb8be0 "lcrwtfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxa
lcrwtfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxalcrwtfsqabknvtfcbpo
onxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxalcrwtfsqabknvtfcb"..., part=0, 
    count=1) at NdbBlob.cpp:1673
#12 0x0889bc5e in NdbBlob::writeDataPrivate (this=0x8e7b150, 
    buf=0x8eb8be0 "lcrwtfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxa
lcrwtfsqabknvtfcbpoonxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxalcrwtfsqabknvtfcbpo
onxsjiqvmhnfikxxhcgoexlkoezvahdbnfqyzgtqxalcrwtfsqabknvtfcb"..., bytes=20789)
    at NdbBlob.cpp:1499
#13 0x0889c504 in NdbBlob::preExecute (this=0x8e7b150, anExecType=NoCommit, 
    batch=@0xb6b99f2f) at NdbBlob.cpp:2310
#14 0x088344c0 in NdbTransaction::execute (this=0x8dd6c70, 
    aTypeOfExec=NdbTransaction::NoCommit, 
    abortOption=NdbOperation::AbortOnError, forceSend=1)
    at NdbTransaction.cpp:307
#15 0x085786d4 in execute_no_commit (h=0x8e69268, trans=0x8dd6c70, 
    force_release=false) at ha_ndbcluster.cc:297
---Type <return> to continue, or q <return> to quit---
#16 0x0856359c in ha_ndbcluster::flush_bulk_insert (this=0x8e69268)
    at ha_ndbcluster.cc:4587
#17 0x08567989 in ha_ndbcluster::ndb_write_row (this=0x8e69268, 
    record=0x8e73a98 "ü", primary_key_update=false, batched_update=false)
    at ha_ndbcluster.cc:3410
#18 0x085688e6 in ha_ndbcluster::write_row (this=0x8e69268, 
    record=0x8e73a98 "ü") at ha_ndbcluster.cc:3186
#19 0x08460206 in handler::ha_write_row (this=0x8e69268, buf=0x8e73a98 "ü")
    at handler.cc:4547
#20 0x083c8156 in write_record (thd=0x8e005b8, table=0x8e796c0, 
    info=0xb6b9a2e8) at sql_insert.cc:1549
#21 0x083cd35d in mysql_insert (thd=0x8e005b8, table_list=0x8df9b18, 
    fields=@0x8e0193c, values_list=@0x8e01960, update_fields=@0x8e01954, 
    update_values=@0x8e01948, duplic=DUP_ERROR, ignore=false)
    at sql_insert.cc:803
#22 0x08326d7a in mysql_execute_command (thd=0x8e005b8) at sql_parse.cc:2608
#23 0x0832d673 in mysql_parse (thd=0x8e005b8, 
    inBuf=0x8df9a18 "insert into t1 values (\n0, repeat(@s2,454), 100, repeat(@s
2,345), NULL)", length=71, found_semicolon=0xb6b9ae98) at sql_parse.cc:5369
#24 0x0832e285 in dispatch_command (command=COM_QUERY, thd=0x8e005b8, 
    packet=0x8e3baa9 "insert into t1 values (\n0, repeat(@s2,454), 100, repeat(@
s2,345), NULL)", packet_length=71) at sql_parse.cc:890
#25 0x0832f734 in do_command (thd=0x8e005b8) at sql_parse.cc:657
---Type <return> to continue, or q <return> to quit---
#26 0x0831bf72 in handle_one_connection (arg=0x8e005b8) at sql_connect.cc:1119
#27 0xb7ec6112 in start_thread () from /lib/libpthread.so.0
#28 0xb7cd248e in clone () from /lib/libc.so.6

How to repeat:
compile with -fstack-protector-all

run any of the flwg tests:
rpl_ndb.rpl_ndb_blob rpl_ndb.rpl_ndb_blob2 ndb.ndb_blob ndb.ndb_dd_backuprestore

Suggested fix:
find out what happens, and whether it's toxic
[10 Apr 2008 23:38] Sveta Smirnova
Thank you for the report.

I can not repeat described behavior with current mysql-6.0 BK sources on Linux. Please try with current sources in your environment and if bug is still repeatable indicate your operating system and configure options you used.
[11 May 2008 23:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
[13 May 2008 8:45] Tatiana Azundris Nuernberg
cannot repeat with 5.1-bk and 6.0-bk, presumed fixed. :-S
thank you for your time and effort!