Bug #36545 Falcon assertion in Table::insert, ASSERT(ret) fails.
Submitted: 6 May 2008 18:52 Modified: 11 Jun 2008 18:54
Reporter: Philip Stoev Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Falcon storage engine Severity:S1 (Critical)
Version:6.0.5 OS:Any
Assigned to: CPU Architecture:Any

[6 May 2008 18:52] Philip Stoev
Description:
When running a subset of the iuds6 workload, Falcon asserted as follows:

#0  0x0000003ba880b132 in pthread_kill () from /lib64/libpthread.so.0
#1  0x00000000007f49fc in write_core (sig=6) at stacktrace.c:305
#2  0x000000000067a803 in handle_segfault (sig=6) at mysqld.cc:2624
#3  <signal handler called>
#4  0x0000003ba880dd4d in raise () from /lib64/libpthread.so.0
#5  0x00000000008ba68c in Error::debugBreak () at Error.cpp:92
#6  0x00000000008ba7a0 in Error::error (string=0xc4e608 "assertion failed at line %d in file %s\n") at Error.cpp:69
#7  0x00000000008ba837 in Error::assertionFailed (fileName=0xc44047 "Table.cpp", line=3014) at Error.cpp:76
#8  0x000000000086fc11 in Table::insert (this=0x2aaaab52a770, transaction=0x2aaaba19baa8, stream=0x2aaab04b1cb8) at Table.cpp:3014
#9  0x0000000000857261 in StorageDatabase::insert (this=0x2aaaaadc31b0, connection=0x2aaabb97a0f0, table=0x2aaaab52a770, stream=0x2aaab04b1cb8)
    at StorageDatabase.cpp:226
#10 0x000000000085da99 in StorageTable::insert (this=0x2aaab04ac730) at StorageTable.cpp:122
#11 0x0000000000850abd in StorageInterface::write_row (this=0x1dc30b10, buff=0x1ac545e0 "А\211R\001") at ha_falcon.cpp:1057
#12 0x000000000078f5ab in handler::ha_write_row (this=0x1dc30b10, buf=0x1ac545e0 "А\211R\001") at handler.cc:5308
#13 0x000000000079ae4c in ha_partition::write_row (this=0x1ac542b0, buf=0x1ac545e0 "А\211R\001") at ha_partition.cc:2812
#14 0x000000000078f5ab in handler::ha_write_row (this=0x1ac542b0, buf=0x1ac545e0 "А\211R\001") at handler.cc:5308
#15 0x0000000000713c67 in write_record (thd=0x1add55f0, table=0x1ad1aca0, info=0x4bd32390) at sql_insert.cc:1566
#16 0x0000000000717ebd in mysql_insert (thd=0x1add55f0, table_list=0x19ca8788, fields=@0x1db67460, values_list=@0x1db674a8, update_fields=@0x1db67490,
    update_values=@0x1db67478, duplic=DUP_ERROR, ignore=false) at sql_insert.cc:819
#17 0x000000000068a34e in mysql_execute_command (thd=0x1add55f0) at sql_parse.cc:2864
#18 0x000000000080a311 in sp_instr_stmt::exec_core (this=0x1db68de8, thd=0x1add55f0, nextp=0x4bd33668) at sp_head.cc:2863
#19 0x000000000080ab16 in sp_lex_keeper::reset_lex_and_exec_core (this=0x1db68e28, thd=0x1add55f0, nextp=0x4bd33668, open_tables=false, instr=0x1db68de8)
    at sp_head.cc:2692
#20 0x000000000080af52 in sp_instr_stmt::execute (this=0x1db68de8, thd=0x1add55f0, nextp=0x4bd33668) at sp_head.cc:2806
#21 0x000000000080c488 in sp_head::execute (this=0x1ad66300, thd=0x1add55f0) at sp_head.cc:1215
#22 0x000000000080cdc1 in sp_head::execute_procedure (this=0x1ad66300, thd=0x1add55f0, args=0x1add78f8) at sp_head.cc:1939
#23 0x000000000068dfa2 in mysql_execute_command (thd=0x1add55f0) at sql_parse.cc:4085
#24 0x000000000068fd34 in mysql_parse (thd=0x1add55f0, inBuf=0x1aba70c0 "CALL ins_tb1_eng1 (@tmp_num, @tmp_word)", length=39, found_semicolon=0x4bd34f50)
    at sql_parse.cc:5623
#25 0x00000000006907a8 in dispatch_command (command=COM_QUERY, thd=0x1add55f0, packet=0x1add7ed1 "CALL ins_tb1_eng1 (@tmp_num, @tmp_word)", packet_length=39)
    at sql_parse.cc:1031
#26 0x00000000006919cd in do_command (thd=0x1add55f0) at sql_parse.cc:723
#27 0x00000000006818b6 in handle_one_connection (arg=0x1add55f0) at sql_connect.cc:1134
#28 0x0000003ba88062f7 in start_thread () from /lib64/libpthread.so.0
#29 0x0000003ba80ce85d in clone () from /lib64/libc.so.6

The assertion is:

                // Do the actual insert

                transaction->addRecord(record);
                bool ret = insert(record, NULL, recordNumber);
HERE>>>         ASSERT(ret);
                inserted = true;

                record->release();

How to repeat:
A simplified test case will hopefully follow.
[7 May 2008 15:34] Kevin Lewis
This is the same assert as Bug #34990.  But That fix should be in the 6.0.5 build that this was found in.
[21 May 2008 14:50] Philip Stoev
Core is at dl360-g5-a://data1/6.0.5/bug36545_vardir
[11 Jun 2008 18:54] Kevin Lewis
Thank you for your bug report. This issue has already been fixed in the latest released version of that product, which you can download at

  http://www.mysql.com/downloads/