#7 0x00007fa422dab662 in __GI___assert_fail (assertion=0x55c8e871e6a0 "false", file=0x55c8e871e7e0 "/data/src/10.5-bug/storage/perfschema/table_helper.cc", line=602, function=0x55c8e871f260 "void set_field_lock_type(Field*, PFS_TL_LOCK_TYPE)") at assert.c:101
#8 0x000055c8e70472c2 in set_field_lock_type (f=0x6190000887c8, lock_type=PFS_TL_WRITE_DELAYED) at /data/src/10.5-bug/storage/perfschema/table_helper.cc:602
#9 0x000055c8e706624f in table_table_handles::read_row_values (this=0x615000021500, table=0x62000003d108, buf=0x61d0001fff28 "", fields=0x619000088070, read_all=false) at /data/src/10.5-bug/storage/perfschema/table_table_handles.cc:201
#10 0x000055c8e6fa597f in PFS_engine_table::read_row (this=0x615000021500, table=0x62000003d108, buf=0x61d0001fff28 "", fields=0x619000088040) at /data/src/10.5-bug/storage/perfschema/pfs_engine_table.cc:454
#11 0x000055c8e6f6c336 in ha_perfschema::rnd_next (this=0x61b00003e328, buf=0x61d0001fff28 "") at /data/src/10.5-bug/storage/perfschema/ha_perfschema.cc:381
#12 0x000055c8e6745138 in handler::ha_rnd_next (this=0x61b00003e328, buf=0x61d0001fff28 "") at /data/src/10.5-bug/sql/handler.cc:2991
#13 0x000055c8e6b73504 in rr_sequential (info=0x62900025d370) at /data/src/10.5-bug/sql/records.cc:511
#14 0x000055c8e5dd19dc in READ_RECORD::read_record (this=0x62900025d370) at /data/src/10.5-bug/sql/records.h:79
#15 0x000055c8e60c505e in join_init_read_record (tab=0x62900025d2a8) at /data/src/10.5-bug/sql/sql_select.cc:21560
#16 0x000055c8e60be442 in sub_select (join=0x62b00003bbc0, join_tab=0x62900025d2a8, end_of_records=false) at /data/src/10.5-bug/sql/sql_select.cc:20612
#17 0x000055c8e60bc663 in do_select (join=0x62b00003bbc0, procedure=0x0) at /data/src/10.5-bug/sql/sql_select.cc:20149
#18 0x000055c8e604a79c in JOIN::exec_inner (this=0x62b00003bbc0) at /data/src/10.5-bug/sql/sql_select.cc:4464
#19 0x000055c8e6047de5 in JOIN::exec (this=0x62b00003bbc0) at /data/src/10.5-bug/sql/sql_select.cc:4245
#20 0x000055c8e604bcf2 in mysql_select (thd=0x62b000069288, tables=0x62b0000389d8, fields=..., conds=0x0, og_num=0, order=0x0, group=0x0, having=0x0, proc_param=0x0, select_options=2147748608, result=0x62b00003bb90, unit=0x62b00006d298, select_lex=0x62b000038378) at /data/src/10.5-bug/sql/sql_select.cc:4669
#21 0x000055c8e601e145 in handle_select (thd=0x62b000069288, lex=0x62b00006d1d0, result=0x62b00003bb90, setup_tables_done_option=0) at /data/src/10.5-bug/sql/sql_select.cc:417
#22 0x000055c8e5f91329 in execute_sqlcom_select (thd=0x62b000069288, all_tables=0x62b0000389d8) at /data/src/10.5-bug/sql/sql_parse.cc:6172
#23 0x000055c8e5f807dd in mysql_execute_command (thd=0x62b000069288) at /data/src/10.5-bug/sql/sql_parse.cc:3901
#24 0x000055c8e5f9c27e in mysql_parse (thd=0x62b000069288, rawbuf=0x62b0000382a8 "SELECT * FROM performance_schema.table_handles", length=46, parser_state=0x7fa419c23960, is_com_multi=false, is_next_command=false) at /data/src/10.5-bug/sql/sql_parse.cc:7957
#25 0x000055c8e5f734c7 in dispatch_command (command=COM_QUERY, thd=0x62b000069288, packet=0x629000249289 "", packet_length=46, is_com_multi=false, is_next_command=false) at /data/src/10.5-bug/sql/sql_parse.cc:1839
#26 0x000055c8e5f7000a in do_command (thd=0x62b000069288) at /data/src/10.5-bug/sql/sql_parse.cc:1358
#27 0x000055c8e638d5eb in do_handle_one_connection (connect=0x61100000a0c8, put_in_cache=true) at /data/src/10.5-bug/sql/sql_connect.cc:1411
#28 0x000055c8e638cf88 in handle_one_connection (arg=0x61100001fec8) at /data/src/10.5-bug/sql/sql_connect.cc:1313
#29 0x000055c8e6f73275 in pfs_spawn_thread (arg=0x6160000eb908) at /data/src/10.5-bug/storage/perfschema/pfs.cc:2201
#30 0x00007fa423289ea7 in start_thread (arg=<optimized out>) at pthread_create.c:477
#31 0x00007fa422e76aef in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
Non-debug build fails the same way.
The test case is not applicable to 10.4 which doesn't have this P_S table.
Attachments
Issue Links
relates to
MDEV-22279Assertion `false' failed in set_field_mdl_type upon quering performance schema
[Current thread is 1 (Thread 0x149bc00fb700 (LWP 27114))]
(gdb) bt
#0 __pthread_kill (threadid=<optimized out>, signo=signo@entry=6) at ../sysdeps/unix/sysv/linux/pthread_kill.c:56
#1 0x000055ca1a24f55c in my_write_core (sig=sig@entry=6) at /test/10.6_dbg/mysys/stacktrace.c:424
#2 0x000055ca199e74de in handle_fatal_signal (sig=6) at /test/10.6_dbg/sql/signal_handler.cc:330
#3 <signal handler called>
#4 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
#5 0x0000149bdd3a0859 in __GI_abort () at abort.c:79
#6 0x0000149bdd3a0729 in __assert_fail_base (fmt=0x149bdd536588 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x55ca1a94089b "false", file=0x55ca1a5e1b18 "/test/10.6_dbg/storage/perfschema/table_helper.cc", line=602, function=<optimized out>) at assert.c:92
#7 0x0000149bdd3b1f36 in __GI___assert_fail (assertion=assertion@entry=0x55ca1a94089b "false", file=file@entry=0x55ca1a5e1b18 "/test/10.6_dbg/storage/perfschema/table_helper.cc", line=line@entry=602, function=function@entry=0x55ca1a5e1d28 "void set_field_lock_type(Field*, PFS_TL_LOCK_TYPE)") at assert.c:101
#8 0x000055ca19d7d466 in set_field_lock_type (f=f@entry=0x149b8403cb28, lock_type=<optimized out>) at /test/10.6_dbg/storage/perfschema/table_helper.cc:602
#9 0x000055ca19d87e07 in table_table_handles::read_row_values (this=0x149b840437b0, table=0x149b84037ee8, buf=<optimized out>, fields=0x149b8403b610, read_all=false) at /test/10.6_dbg/storage/perfschema/table_table_handles.cc:201
#10 0x000055ca19d3e66e in PFS_engine_table::read_row (this=0x149b840437b0, table=0x149b84037ee8, buf=buf@entry=0x149b8403c030 "", fields=0x149b8403b5e0) at /test/10.6_dbg/storage/perfschema/pfs_engine_table.cc:454
#11 0x000055ca19d291b7 in ha_perfschema::rnd_next (this=0x149b8403ba40, buf=0x149b8403c030 "") at /test/10.6_dbg/storage/perfschema/ha_perfschema.cc:362
#12 0x000055ca199ef135 in handler::ha_rnd_next (this=0x149b8403ba40, buf=0x149b8403c030 "") at /test/10.6_dbg/sql/handler.cc:3066
#13 0x000055ca19bc36c1 in rr_sequential (info=0x149b84017f70) at /test/10.6_dbg/sql/records.h:82
#14 0x000055ca19785668 in READ_RECORD::read_record (this=0x149b84017f70) at /test/10.6_dbg/sql/records.h:81
#15 join_init_read_record (tab=0x149b84017ea8) at /test/10.6_dbg/sql/sql_select.cc:21634
#16 0x000055ca1976c0a6 in sub_select (join=0x149b84015ec0, join_tab=0x149b84017ea8, end_of_records=<optimized out>) at /test/10.6_dbg/sql/sql_select.cc:20656
#17 0x000055ca197a4b4c in do_select (procedure=0x0, join=0x149b84015ec0) at /test/10.6_dbg/sql/sql_select.cc:20206
#18 JOIN::exec_inner (this=this@entry=0x149b84015ec0) at /test/10.6_dbg/sql/sql_select.cc:4476
#19 0x000055ca197a4fbc in JOIN::exec (this=this@entry=0x149b84015ec0) at /test/10.6_dbg/sql/sql_select.cc:4256
#20 0x000055ca197a321c in mysql_select (thd=thd@entry=0x149b84000db8, tables=0x149b84012fd0, fields=@0x149b84012b08: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x149b84012f60, last = 0x149b84017070, elements = 8}, <No data fields>}, conds=0x0, og_num=0, order=0x0, group=0x0, having=0x0, proc_param=0x0, select_options=2147748608, result=0x149b84015e98, unit=0x149b84004f88, select_lex=0x149b840129b8) at /test/10.6_dbg/sql/sql_select.cc:4729
#21 0x000055ca197a34e2 in handle_select (thd=thd@entry=0x149b84000db8, lex=lex@entry=0x149b84004ec0, result=result@entry=0x149b84015e98, setup_tables_done_option=setup_tables_done_option@entry=0) at /test/10.6_dbg/sql/sql_select.cc:417
#22 0x000055ca197162b0 in execute_sqlcom_select (thd=thd@entry=0x149b84000db8, all_tables=0x149b84012fd0) at /test/10.6_dbg/sql/sql_parse.cc:6138
#23 0x000055ca19722de6 in mysql_execute_command (thd=thd@entry=0x149b84000db8) at /test/10.6_dbg/sql/sql_parse.cc:3834
#24 0x000055ca1970f21a in mysql_parse (thd=thd@entry=0x149b84000db8, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x149bc00fa3d0) at /test/10.6_dbg/sql/sql_parse.cc:7906
#25 0x000055ca1971d30b in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x149b84000db8, packet=packet@entry=0x149b8401ad09 "", packet_length=packet_length@entry=46) at /test/10.6_dbg/sql/sql_class.h:1295
#26 0x000055ca1972063d in do_command (thd=0x149b84000db8) at /test/10.6_dbg/sql/sql_parse.cc:1365
#27 0x000055ca1987c1ab in do_handle_one_connection (connect=<optimized out>, connect@entry=0x55ca1d86b308, put_in_cache=put_in_cache@entry=true) at /test/10.6_dbg/sql/sql_connect.cc:1410
#28 0x000055ca1987c8af in handle_one_connection (arg=arg@entry=0x55ca1d86b308) at /test/10.6_dbg/sql/sql_connect.cc:1312
#29 0x000055ca19d3027d in pfs_spawn_thread (arg=0x55ca1d762f08) at /test/10.6_dbg/storage/perfschema/pfs.cc:2201
#30 0x0000149bdd8ae609 in start_thread (arg=<optimized out>) at pthread_create.c:477
#31 0x0000149bdd49d293 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
#7 0x000055a321d0d9aa in ha_perfschema::rnd_next (buf=0x14714402e030 "", this=0x14714402dab0) at /test/10.9_opt/storage/perfschema/ha_perfschema.cc:362
#8 ha_perfschema::rnd_next (this=0x14714402dab0, buf=0x14714402e030 "") at /test/10.9_opt/storage/perfschema/ha_perfschema.cc:348
#9 0x000055a321ac8777 in handler::ha_rnd_next (this=0x14714402dab0, buf=0x14714402e030 "") at /test/10.9_opt/sql/handler.cc:3393
#10 0x000055a3217aa244 in rr_sequential (info=0x147144030640) at /test/10.9_opt/sql/records.h:82
#11 0x000055a3218c2d76 in sub_select (end_of_records=false, join_tab=0x147144030578, join=0x1471440143a0) at /test/10.9_opt/sql/sql_select.cc:21092
#12 sub_select (join=0x1471440143a0, join_tab=0x147144030578, end_of_records=false) at /test/10.9_opt/sql/sql_select.cc:21024
#13 0x000055a3218f0bf7 in do_select (procedure=<optimized out>, join=0x1471440143a0) at /test/10.9_opt/sql/sql_select.cc:20640
#14 JOIN::exec_inner (this=0x1471440143a0) at /test/10.9_opt/sql/sql_select.cc:4749
#15 0x000055a3218f0fb8 in JOIN::exec (this=this@entry=0x1471440143a0) at /test/10.9_opt/sql/sql_select.cc:4527
#16 0x000055a3218ef0c1 in mysql_select (thd=0x147144000c58, tables=0x147144011068, fields=@0x147144010d08: {<base_list> = {<Sql_alloc> = {<No data fields>}, first = 0x147144010ff8, last = 0x14714402f720, elements = 8}, <No data fields>}, conds=0x0, og_num=0, order=0x0, group=0x0, having=0x0, proc_param=0x0, select_options=<optimized out>, result=0x147144014378, unit=0x147144004ea8, select_lex=0x147144010a68) at /test/10.9_opt/sql/sql_select.cc:5007
#17 0x000055a3218ef877 in handle_select (thd=thd@entry=0x147144000c58, lex=lex@entry=0x147144004dd0, result=result@entry=0x147144014378, setup_tables_done_option=setup_tables_done_option@entry=0) at /test/10.9_opt/sql/sql_select.cc:543
#18 0x000055a321870301 in execute_sqlcom_select (thd=0x147144000c58, all_tables=0x147144011068) at /test/10.9_opt/sql/sql_parse.cc:6252
#19 0x000055a32187e62e in mysql_execute_command (thd=0x147144000c58, is_called_from_prepared_stmt=<optimized out>) at /test/10.9_opt/sql/sql_parse.cc:3943
#20 0x000055a32186b086 in mysql_parse (thd=0x147144000c58, rawbuf=<optimized out>, length=<optimized out>, parser_state=<optimized out>) at /test/10.9_opt/sql/sql_parse.cc:8027
#21 0x000055a321877235 in dispatch_command (command=COM_QUERY, thd=0x147144000c58, packet=<optimized out>, packet_length=<optimized out>, blocking=<optimized out>) at /test/10.9_opt/sql/sql_class.h:1362
#22 0x000055a321879427 in do_command (thd=0x147144000c58, blocking=blocking@entry=true) at /test/10.9_opt/sql/sql_parse.cc:1402
#23 0x000055a321998d77 in do_handle_one_connection (connect=<optimized out>, put_in_cache=true) at /test/10.9_opt/sql/sql_connect.cc:1418
#24 0x000055a3219990bd in handle_one_connection (arg=arg@entry=0x55a3246a65f8) at /test/10.9_opt/sql/sql_connect.cc:1312
#25 0x000055a321d127b1 in pfs_spawn_thread (arg=0x55a3246a6668) at /test/10.9_opt/storage/perfschema/pfs.cc:2201
#26 0x00001471f681c609 in start_thread (arg=<optimized out>) at pthread_create.c:477
#27 0x00001471f640a293 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
80179e8, unit=0x14a0880051c8, select_lex=0x14a0880140d8) at /test/10.9_dbg/sql/sql_select.cc:5007
#17 0x00005641adac1b84 in handle_select (thd=thd@entry=0x14a088000db8, lex=lex@entry=0x14a0880050f0, result=result@entry
=0x14a0880179e8, setup_tables_done_option=setup_tables_done_option@entry=0) at /test/10.9_dbg/sql/sql_select.cc:543
#18 0x00005641ada21124 in execute_sqlcom_select (thd=thd@entry=0x14a088000db8, all_tables=0x14a0880146d8) at /test/10.9_dbg/sql/sql_parse.cc:6252
#19 0x00005641ada2e08b in mysql_execute_command (thd=thd@entry=0x14a088000db8, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false) at /test/10.9_dbg/sql/sql_parse.cc:3943
#20 0x00005641ada1a315 in mysql_parse (thd=thd@entry=0x14a088000db8, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x14a0f0094400) at /test/10.9_dbg/sql/sql_parse.cc:8027
#21 0x00005641ada28fb1 in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x14a088000db8, packet=packet@entry=0x14a08801a129 "", packet_length=packet_length@entry=46, blocking=blocking@entry=true) at /test/10.9_dbg/sql/sql_class.h:1362
#22 0x00005641ada2c3f8 in do_command (thd=0x14a088000db8, blocking=blocking@entry=true) at /test/10.9_dbg/sql/sql_parse.cc:1402
#23 0x00005641adba6fc4 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x5641b1c78298, put_in_cache=put_in_cache@entry=true) at /test/10.9_dbg/sql/sql_connect.cc:1418
#24 0x00005641adba75c9 in handle_one_connection (arg=arg@entry=0x5641b1c78298) at /test/10.9_dbg/sql/sql_connect.cc:1312
#25 0x00005641ae02dd67 in pfs_spawn_thread (arg=0x5641b1b6faf8) at /test/10.9_dbg/storage/perfschema/pfs.cc:2201
#26 0x000014a101a12609 in start_thread (arg=<optimized out>) at pthread_create.c:477
#27 0x000014a101600293 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
Likely to be related to MDEV-22279.