[MDEV-29830] Assertion `table->versioned()' in THD::vers_insert_history_fast Created: 2022-10-20  Updated: 2022-10-26  Resolved: 2022-10-26

Status: Closed
Project: MariaDB Server
Component/s: Versioned Tables
Affects Version/s: N/A
Fix Version/s: 10.11.1

Type: Bug Priority: Critical
Reporter: Elena Stepanova Assignee: Sergei Golubchik
Resolution: Fixed Votes: 0
Labels: None

Issue Links:
Problem/Incident
is caused by MDEV-16546 System versioning setting to allow hi... Closed
Relates

 Description   

CREATE TABLE t1 (a INT) WITH SYSTEM VERSIONING;
INSERT INTO t1 VALUES (1),(2);
 
CREATE TABLE t2 (a TIMESTAMP);
INSERT INTO t2 (a) VALUES (NOW()),(NOW());
 
SELECT * from t2 WHERE a IN (SELECT row_start FROM t1);

bb-10.11-MDEV-16546 6dc61733af

mariadbd: /data/src/bb-10.11-MDEV-16546/sql/sql_class.h:5565: bool THD::vers_insert_history_fast(const TABLE*): Assertion `table->versioned()' failed.
221020  3:17:01 [ERROR] mysqld got signal 6 ;
 
#7  0x00007f4af2d6d662 in __GI___assert_fail (assertion=0x560234133a20 "table->versioned()", file=0x5602341338a0 "/data/src/bb-10.11-MDEV-16546/sql/sql_class.h", line=5565, function=0x560234133a60 "bool THD::vers_insert_history_fast(const TABLE*)") at assert.c:101
#8  0x000056023226d885 in THD::vers_insert_history_fast (this=0x62c0000b0218, table=0x61f000015eb8) at /data/src/bb-10.11-MDEV-16546/sql/sql_class.h:5565
#9  0x0000560232263183 in fill_record (thd=0x62c0000b0218, table=0x61f000015eb8, ptr=0x61f000016838, values=..., ignore_errors=true, use_value=false) at /data/src/bb-10.11-MDEV-16546/sql/sql_base.cc:9219
#10 0x00005602324ee8bd in end_sj_materialize (join=0x6290000e9340, join_tab=0x62900026b018, end_of_records=false) at /data/src/bb-10.11-MDEV-16546/sql/sql_select.cc:13400
#11 0x000056023252753d in evaluate_join_record (join=0x6290000e9340, join_tab=0x62900026ac60, error=0) at /data/src/bb-10.11-MDEV-16546/sql/sql_select.cc:21994
#12 0x0000560232526542 in sub_select (join=0x6290000e9340, join_tab=0x62900026ac60, end_of_records=false) at /data/src/bb-10.11-MDEV-16546/sql/sql_select.cc:21764
#13 0x00005602328f6beb in join_tab_execution_startup (tab=0x62900026c5f0) at /data/src/bb-10.11-MDEV-16546/sql/opt_subselect.cc:5757
#14 0x0000560232526257 in sub_select (join=0x6290000e9340, join_tab=0x62900026c5f0, end_of_records=false) at /data/src/bb-10.11-MDEV-16546/sql/sql_select.cc:21749
#15 0x000056023252753d in evaluate_join_record (join=0x6290000e9340, join_tab=0x62900026c238, error=0) at /data/src/bb-10.11-MDEV-16546/sql/sql_select.cc:21994
#16 0x0000560232526542 in sub_select (join=0x6290000e9340, join_tab=0x62900026c238, end_of_records=false) at /data/src/bb-10.11-MDEV-16546/sql/sql_select.cc:21764
#17 0x0000560232524ed5 in do_select (join=0x6290000e9340, procedure=0x0) at /data/src/bb-10.11-MDEV-16546/sql/sql_select.cc:21309
#18 0x00005602324b496b in JOIN::exec_inner (this=0x6290000e9340) at /data/src/bb-10.11-MDEV-16546/sql/sql_select.cc:4813
#19 0x00005602324b2259 in JOIN::exec (this=0x6290000e9340) at /data/src/bb-10.11-MDEV-16546/sql/sql_select.cc:4591
#20 0x00005602324b5c43 in mysql_select (thd=0x62c0000b0218, tables=0x6290000e6920, fields=..., conds=0x6290000e8740, og_num=0, order=0x0, group=0x0, having=0x0, proc_param=0x0, select_options=2164525824, result=0x6290000e9310, unit=0x62c0000b4658, select_lex=0x6290000e6310) at /data/src/bb-10.11-MDEV-16546/sql/sql_select.cc:5071
#21 0x000056023248b529 in handle_select (thd=0x62c0000b0218, lex=0x62c0000b4580, result=0x6290000e9310, setup_tables_done_option=0) at /data/src/bb-10.11-MDEV-16546/sql/sql_select.cc:582
#22 0x00005602323d1426 in execute_sqlcom_select (thd=0x62c0000b0218, all_tables=0x6290000e6920) at /data/src/bb-10.11-MDEV-16546/sql/sql_parse.cc:6261
#23 0x00005602323c0264 in mysql_execute_command (thd=0x62c0000b0218, is_called_from_prepared_stmt=false) at /data/src/bb-10.11-MDEV-16546/sql/sql_parse.cc:3945
#24 0x00005602323daffb in mysql_parse (thd=0x62c0000b0218, rawbuf=0x6290000e6238 "SELECT * from t2 WHERE a IN (SELECT row_start FROM t1)", length=54, parser_state=0x7f4ae9a88b20) at /data/src/bb-10.11-MDEV-16546/sql/sql_parse.cc:8023
#25 0x00005602323b390e in dispatch_command (command=COM_QUERY, thd=0x62c0000b0218, packet=0x629000253219 "", packet_length=54, blocking=true) at /data/src/bb-10.11-MDEV-16546/sql/sql_parse.cc:1894
#26 0x00005602323b0da9 in do_command (thd=0x62c0000b0218, blocking=true) at /data/src/bb-10.11-MDEV-16546/sql/sql_parse.cc:1407
#27 0x00005602327f0099 in do_handle_one_connection (connect=0x6080000025b8, put_in_cache=true) at /data/src/bb-10.11-MDEV-16546/sql/sql_connect.cc:1416
#28 0x00005602327efa5a in handle_one_connection (arg=0x608000002538) at /data/src/bb-10.11-MDEV-16546/sql/sql_connect.cc:1318
#29 0x00005602332d9a36 in pfs_spawn_thread (arg=0x617000004d98) at /data/src/bb-10.11-MDEV-16546/storage/perfschema/pfs.cc:2201
#30 0x00007f4af3249ea7 in start_thread (arg=<optimized out>) at pthread_create.c:477
#31 0x00007f4af2e38aef in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95


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