Bug #40569 mysqld core in ha_ndbcluster_cond.cc:
Submitted: 6 Nov 2008 22:59 Modified: 25 Nov 2009 15:00
Reporter: Jonathan Miller Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Cluster: Replication Severity:S2 (Serious)
Version:mysql-5.1-telco-6.2 OS:Linux
Assigned to: Martin Skold CPU Architecture:Any
Tags: mysql5.1-telco-6.2 (debug)

[6 Nov 2008 22:59] Jonathan Miller
Description:
Found during investigation as to why all Replication tests have been failing in ACRT Framework.

#0  0x0000003a1c60b132 in pthread_kill () from /lib64/libpthread.so.0
(gdb) bt
#0  0x0000003a1c60b132 in pthread_kill () from /lib64/libpthread.so.0
#1  0x0000000000626161 in handle_segfault (sig=11) at mysqld.cc:2513
#2  <signal handler called>
#3  0x0000000000000000 in ?? ()
#4  0x00000000007cf3a5 in ndb_serialize_cond (item=0x86d6590, arg=<value optimized out>)
    at ha_ndbcluster_cond.cc:375
#5  0x0000000000594940 in Item_func::traverse_cond (this=0x86d6618,
    traverser=0x7ced40 <ndb_serialize_cond(Item const*, void*)>, argument=0x40bac720,
    order=141382512) at item_func.cc:233
#6  0x00000000007cec2f in ha_ndbcluster_cond::serialize_cond (this=<value optimized out>,
    cond=0x86d6618, ndb_cond=0x86d6a20, table=<value optimized out>,
    ndb_table=<value optimized out>) at ha_ndbcluster_cond.cc:1000
#7  0x00000000007cecf0 in ha_ndbcluster_cond::cond_push (this=0x8751020, cond=0x86d6618,
    table=0x8819470, ndb_table=0x86d9830) at ha_ndbcluster_cond.cc:951
#8  0x00000000006bef8d in mysql_update (thd=0x86f9d90, table_list=0x86d54b8,
    fields=@0x86fbca8, values=@0x86fc080, conds=0x86d6618, order_num=<value optimized out>,
    order=0x0, limit=18446744073709551615, handle_duplicates=DUP_ERROR, ignore=false)
    at sql_update.cc:526
#9  0x0000000000639480 in mysql_execute_command (thd=0x86f9d90) at sql_parse.cc:2914
#10 0x000000000063c532 in mysql_parse (thd=0x86f9d90,
    inBuf=0x874a770 "UPDATE TPCB.trans set count =  NAME_CONST('counter',501), lastTransTime = now(), \n", ' ' <repeats 27 times>, "TPS =  NAME_CONST('tps',20.04) where scriptId =  NAME_CONST('id',_latin1'ndb183\\0\\0\\0\\0' CO"..., length=226, found_semicolon=0x40badfa8)
    at sql_parse.cc:5730
#11 0x00000000006eafc4 in Query_log_event::do_apply_event (this=0x86e9650, rli=0x86cb5a0,
    query_arg=0x874a770 "UPDATE TPCB.trans set count =  NAME_CONST('counter',501), lastTransTime = now(), \n", ' ' <repeats 27 times>, "TPS =  NAME_CONST('tps',20.04) where scriptId =  NAME_CONST('id',_latin1'ndb183\\0\\0\\0\\0' CO"..., q_len_arg=226) at log_event.cc:3011
#12 0x000000000075b221 in apply_event_and_update_pos (ev=0x86e9650, thd=0x0, rli=0x86cb5a0,
    skip=true) at log_event.h:1030
#13 0x0000000000760319 in handle_slave_sql (arg=0x1) at slave.cc:2058
#14 0x0000003a1c6062f7 in start_thread () from /lib64/libpthread.so.0
#15 0x0000003a1bece85d in clone () from /lib64/libc.so.6
(gdb) frame 4
#4  0x00000000007cf3a5 in ndb_serialize_cond (item=0x86d6590, arg=<value optimized out>)
    at ha_ndbcluster_cond.cc:375
375     ha_ndbcluster_cond.cc: No such file or directory.
        in ha_ndbcluster_cond.cc

I am still looking at this, but wanted to go ahead and start a report.

How to repeat:
1) using ndb18 inside the /space/cluster_rep_auto/ directory
  $>sh -x scripts/boot.sh --clone=mysql-5.1-telco-6.2 --CONF=./cr-autotest.conf --start-and-exit clst-rep

2) from a different prompt in the same directory
   $>sh -x drivers/tpcb-tester.sh ./cr-autotest.conf

NOTE: I have not repeated it as of yet as I just found it, but these are the steps which produced the current core.

Suggested fix:
N/A
[9 Apr 2009 13:18] Jonathan Miller
WA == disable condition push down.
[25 Nov 2009 15:00] Martin Skold
This has not been possible to repeat, and no new related bugs have been reported
by any users. The code has been modified, so possibly the bug is already fixed.