Details
-
Type:
Bug
-
Status: Closed
-
Resolution: Not a Bug
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: None
-
Labels:
Description
The following query:
SELECT table1 .`col_int_nokey` field1 , table2 .`col_varchar_key` field2 , table1 .`col_varchar_key` field3 , table2 .`col_time_key` field4 , table2 .`col_date_key` field5 , table2 .`col_int_key` field6 , table2 .`col_date_key` field7 , table1 .`col_varchar_key` field8 FROM CC table1 STRAIGHT_JOIN ( CC table2 JOIN CC table3 ON table3 .`col_varchar_nokey` = table2 .`col_varchar_key` ) ON table2 .`col_int_nokey` AND table3 .`col_varchar_key` = table2 .`col_varchar_nokey` GROUP BY field1 , field3 , field4 , field5 , field6 , field7 , field8 ORDER BY field1 , field2 , field3 , field4 , field5 , field6 , field7 , field8 , table1 .`col_date_key` DESC , table1 .`col_date_key` ASC
caused the following sporadic crash
#7 0x08749d71 in my_print_stacktrace (stack_bottom=0x9a196360 "`\330\036\v\206", thread_stack=294912) at stacktrace.c:136
#8 0x0827f7bc in handle_segfault (sig=11) at mysqld.cc:2645
#9 <signal handler called>
#10 0x08656c89 in build_template (prebuilt=0xaeb74110, thd=0xb1ed860, table=0xaeba5820, file=0xaeba5f18, templ_type=1) at handler/ha_innodb.cc:4302
#11 0x08659204 in ha_innobase::change_active_index (this=0xaeba5f18, keynr=0) at handler/ha_innodb.cc:5647
#12 0x08659764 in ha_innobase::rnd_init (this=0xaeba5f18, scan=true) at handler/ha_innodb.cc:5858
#13 0x081ab3cb in handler::ha_rnd_init (this=0xaeba5f18, scan=true) at handler.h:1547
#14 0x083c2172 in init_read_record (info=0xaeb8a454, thd=0xb1ed860, table=0xaeba5820, select=0xaeb8ab80, use_record_cache=1, print_error=true,
disable_rr_cache=false) at records.cc:256
#15 0x08321ccd in join_init_read_record (tab=0xaeb8a40c) at sql_select.cc:14058
#16 0x082da63e in JOIN_TAB_SCAN::open (this=0xaeb8b110) at sql_join_cache.cc:3009
#17 0x082d931d in JOIN_CACHE::join_matching_records (this=0xaeb8b058, skip_last=false) at sql_join_cache.cc:2084
#18 0x082d8fe0 in JOIN_CACHE::join_records (this=0xaeb8b058, skip_last=false) at sql_join_cache.cc:1926
#19 0x0831fecf in sub_select_cache (join=0xaeb991a8, join_tab=0xaeb8a40c, end_of_records=true) at sql_select.cc:13083
#20 0x083200e8 in sub_select (join=0xaeb991a8, join_tab=0xaeb8a238, end_of_records=true) at sql_select.cc:13245
#21 0x0831f700 in do_select (join=0xaeb991a8, fields=0x0, table=0xaeb8b900, procedure=0x0) at sql_select.cc:12841
#22 0x08303adf in JOIN::exec (this=0xaeb991a8) at sql_select.cc:1990
#23 0x08305df4 in mysql_select (thd=0xb1ed860, rref_pointer_array=0xb1ef2dc, tables=0xaeb70c08, wild_num=0, fields=..., conds=0x0, og_num=17,
order=0xaeb801d0, group=0xaeb7fc20, having=0x0, proc_param=0x0, select_options=2147764736, result=0xaeb80a30, unit=0xb1eef40, select_lex=0xb1ef1d8)
at sql_select.cc:2613
#24 0x082fe4af in handle_select (thd=0xb1ed860, lex=0xb1eeee4, result=0xaeb80a30, setup_tables_done_option=0) at sql_select.cc:277
#25 0x0829b6d4 in execute_sqlcom_select (thd=0xb1ed860, all_tables=0xaeb70c08) at sql_parse.cc:5081
#26 0x082920b4 in mysql_execute_command (thd=0xb1ed860) at sql_parse.cc:2265
#27 0x0829d8b5 in mysql_parse (thd=0xb1ed860,
inBuf=0xaeb6fe58 "SELECT table1 .`col_int_nokey` field1 , table2 .`col_varchar_key` field2 , table1 .`col_varchar_key` field3 , table2 .`col_time_key` field4 , table2 .`col_date_key` field5 , table2 .`col_int_key`"..., length=718, found_semicolon=0x9a196230) at sql_parse.cc:6027
#28 0x0828fae6 in dispatch_command (command=COM_QUERY, thd=0xb1ed860,
packet=0xb1fd721 " SELECT table1 .`col_int_nokey` field1 , table2 .`col_varchar_key` field2 , table1 .`col_varchar_key` field3 , table2 .`col_time_key` field4 , table2 .`col_date_key` field5 , table2 .`col_int_key"..., packet_length=722) at sql_parse.cc:1184
#29 0x0828ef8c in do_command (thd=0xb1ed860) at sql_parse.cc:890
#30 0x0828c0ec in handle_one_connection (arg=0xb1ed860) at sql_connect.cc:1153
#31 0x00bea919 in start_thread () from /lib/libpthread.so.0
#32 0x00b2ccbe in clone () from /lib/libc.so.6
and the following valgrind warning:
==18692== Conditional jump or move depends on uninitialised value(s)
==18692== at 0x86BDC6A: rw_lock_set_writer_id_and_recursion_flag (sync0rw.ic:283)
==18692== by 0x86BE5E9: rw_lock_x_lock_low (sync0rw.c:558)
==18692== by 0x86BE6B7: rw_lock_x_lock_func (sync0rw.c:617)
==18692== by 0x86E406A: btr_search_check_free_space_in_heap (btr0sea.c:145)
==18692== by 0x86E4B18: btr_search_info_update_slow (btr0sea.c:604)
==18692== by 0x86E400E: btr_search_info_update (btr0sea.ic:83)
==18692== by 0x86DB425: btr_cur_search_to_nth_level (btr0cur.c:708)
==18692== by 0x86E3093: btr_pcur_open_with_no_init (btr0pcur.ic:555)
==18692== by 0x86AEBB6: row_sel_get_clust_rec_for_mysql (row0sel.c:2875)
==18692== by 0x86B0F3A: row_search_for_mysql (row0sel.c:4299)
==18692== by 0x8658BF5: ha_innobase::index_read(unsigned char*, unsigned char const*, unsigned int, ha_rkey_function) (ha_innodb.cc:5496)
==18692== by 0x83D0C43: handler::index_read_map(unsigned char*, unsigned char const*, unsigned long, ha_rkey_function) (handler.h:1767)
==18692== by 0x81AB73A: handler::ha_index_read_map(unsigned char*, unsigned char const*, unsigned long, ha_rkey_function) (sql_class.h:3392)
==18692== by 0x8321801: join_read_always_key(st_join_table*) (sql_select.cc:13925)
==18692== by 0x8320255: sub_select(JOIN*, st_join_table*, bool) (sql_select.cc:13292)
==18692== by 0x82D9693: JOIN_CACHE::generate_full_extensions(unsigned char*) (sql_join_cache.cc:2224)
Gliffy Diagrams
Attachments
Activity
- All
- Comments
- Work Log
- History
- Activity
- Transitions
Re: Crash/valgrind warning in Innodb from a join cache query
No longer repeatable.