[MDEV-33330] Server crash or assertion failure in binlog_get_pending_rows_event Created: 2024-01-30  Updated: 2024-01-30

Status: Open
Project: MariaDB Server
Component/s: Partitioning, Replication, Versioned Tables
Affects Version/s: 11.2, 11.3, 11.4
Fix Version/s: 11.2, 11.3

Type: Bug Priority: Critical
Reporter: Elena Stepanova Assignee: Nikita Malyavin
Resolution: Unresolved Votes: 0
Labels: None

Issue Links:
Problem/Incident
is caused by MDEV-16329 Engine-independent online ALTER TABLE Closed

 Description   

--source include/have_partition.inc
--source include/have_log_bin.inc
 
create or replace table t (x int) with system versioning
partition by system_time interval 1 minute auto partitions 3;
insert into t values (1);
 
--connect (con1,localhost,root,,)
set timestamp= @@timestamp+120;
update t set x= x + 1;
 
# Cleanup
drop table t;

11.2 985e3dfc05c697b8de1f083712275bdb48d42fc2 debug

mariadbd: /data/bld/11.2-asan/sql/log.cc:6175: Rows_log_event* binlog_get_pending_rows_event(binlog_cache_mngr*, bool): Assertion `cache_mngr' failed.
240130 15:28:21 [ERROR] mysqld got signal 6 ;
 
#9  0x00007f16cc253e32 in __GI___assert_fail (assertion=0x55749f6ce4e0 "cache_mngr", file=0x55749f6c62e0 "/data/bld/11.2-asan/sql/log.cc", line=6175, function=0x55749f6ce520 "Rows_log_event* binlog_get_pending_rows_event(binlog_cache_mngr*, bool)") at ./assert/assert.c:101
#10 0x000055749dca368e in binlog_get_pending_rows_event (cache_mngr=0x0, use_trans_cache=false) at /data/bld/11.2-asan/sql/log.cc:6175
#11 0x000055749cf1f54b in THD::binlog_need_stmt_format (this=0x62c000100218, is_transactional=false) at /data/bld/11.2-asan/sql/sql_class.h:3027
#12 0x000055749d398301 in Sql_cmd_update::update_single_table (this=0x62900028ae70, thd=0x62c000100218) at /data/bld/11.2-asan/sql/sql_update.cc:1214
#13 0x000055749d3aae8d in Sql_cmd_update::execute_inner (this=0x62900028ae70, thd=0x62c000100218) at /data/bld/11.2-asan/sql/sql_update.cc:3071
#14 0x000055749d1f06d4 in Sql_cmd_dml::execute (this=0x62900028ae70, thd=0x62c000100218) at /data/bld/11.2-asan/sql/sql_select.cc:33604
#15 0x000055749d00f96e in mysql_execute_command (thd=0x62c000100218, is_called_from_prepared_stmt=false) at /data/bld/11.2-asan/sql/sql_parse.cc:4408
#16 0x000055749d027255 in mysql_parse (thd=0x62c000100218, rawbuf=0x62900028a238 "update t set x= x + 1", length=21, parser_state=0x7f16c01d49f0) at /data/bld/11.2-asan/sql/sql_parse.cc:7857
#17 0x000055749cfff389 in dispatch_command (command=COM_QUERY, thd=0x62c000100218, packet=0x629000280219 "update t set x= x + 1", packet_length=21, blocking=true) at /data/bld/11.2-asan/sql/sql_parse.cc:1893
#18 0x000055749cffc0c6 in do_command (thd=0x62c000100218, blocking=true) at /data/bld/11.2-asan/sql/sql_parse.cc:1406
#19 0x000055749d4cbe7d in do_handle_one_connection (connect=0x608000002f38, put_in_cache=true) at /data/bld/11.2-asan/sql/sql_connect.cc:1437
#20 0x000055749d4cb83e in handle_one_connection (arg=0x608000002f38) at /data/bld/11.2-asan/sql/sql_connect.cc:1339
#21 0x000055749e0f10ac in pfs_spawn_thread (arg=0x617000006618) at /data/bld/11.2-asan/storage/perfschema/pfs.cc:2201
#22 0x00007f16cc2a8044 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
#23 0x00007f16cc32861c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

11.2 985e3dfc05c697b8de1f083712275bdb48d42fc2 non-debug

#2  <signal handler called>
#3  binlog_get_pending_rows_event (cache_mngr=0x0, use_trans_cache=use_trans_cache@entry=false) at /data/bld/11.2-rel/sql/log_cache.h:60
#4  0x000055aea8d46a78 in THD::binlog_need_stmt_format (is_transactional=<optimized out>, this=0x7fb334000c68) at /data/bld/11.2-rel/sql/sql_class.h:3027
#5  Sql_cmd_update::update_single_table (this=0x7fb334011798, thd=0x7fb334000c68) at /data/bld/11.2-rel/sql/sql_update.cc:1214
#6  0x000055aea8d46ba5 in Sql_cmd_update::execute_inner (this=0x7fb334011798, thd=0x7fb334000c68) at /data/bld/11.2-rel/sql/sql_update.cc:3071
#7  0x000055aea8ca2dad in Sql_cmd_dml::execute (this=0x7fb334011798, thd=0x7fb334000c68) at /data/bld/11.2-rel/sql/sql_select.cc:33604
#8  0x000055aea8c6bf96 in mysql_execute_command (thd=thd@entry=0x7fb334000c68, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false) at /data/bld/11.2-rel/sql/sql_parse.cc:4408
#9  0x000055aea8c6fc45 in mysql_parse (thd=0x7fb334000c68, rawbuf=<optimized out>, length=<optimized out>, parser_state=<optimized out>) at /data/bld/11.2-rel/sql/sql_parse.cc:7857
#10 0x000055aea8c71b85 in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x7fb334000c68, packet=packet@entry=0x7fb3340088c9 "update t set x= x + 1", packet_length=packet_length@entry=21, blocking=blocking@entry=true) at /data/bld/11.2-rel/sql/sql_parse.cc:1992
#11 0x000055aea8c73197 in do_command (thd=0x7fb334000c68, blocking=blocking@entry=true) at /data/bld/11.2-rel/sql/sql_parse.cc:1406
#12 0x000055aea8d8a847 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x55aeab908a78, put_in_cache=put_in_cache@entry=true) at /data/bld/11.2-rel/sql/sql_connect.cc:1437
#13 0x000055aea8d8abdd in handle_one_connection (arg=arg@entry=0x55aeab908a78) at /data/bld/11.2-rel/sql/sql_connect.cc:1339
#14 0x000055aea90af107 in pfs_spawn_thread (arg=0x55aeab8862b8) at /data/bld/11.2-rel/storage/perfschema/pfs.cc:2201
#15 0x00007fb3534a8044 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
#16 0x00007fb35352861c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81

It appears that the failure started happening after online ALTER push (MDEV-16329)


Generated at Thu Feb 08 10:38:07 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.