[MDEV-31667] SEGV in trx_undo_report_row_operation during some INSERT Created: 2023-07-11  Updated: 2023-12-07

Status: Stalled
Project: MariaDB Server
Component/s: Storage Engine - InnoDB
Affects Version/s: 11.2.0
Fix Version/s: 10.11, 11.0, 11.1, 11.2, 11.3

Type: Bug Priority: Major
Reporter: Matthias Leich Assignee: Thirunarayanan Balathandayuthapani
Resolution: Unresolved Votes: 0
Labels: rr-profile

Issue Links:
Relates
relates to MDEV-24621 In bulk insert, pre-sort and build in... Closed

 Description   

origin/bb-11.2-MDEV-14795_1 1779cb1af979cad1abe9d5c3ed4d37b6503175aa 2023-07-11T20:25:49+05:30
Per Thiru this problem is a MDEV-24621 regression and not specific to the development tree above.
 
Thread 3 received signal SIGSEGV, Segmentation fault.
(rr) bt
#0  0x00005648a5cf6cc6 in trx_undo_report_row_operation (thr=thr@entry=0x6270000adbd0, index=index@entry=0x616002b45008, clust_entry=clust_entry@entry=0x61d00094a308, update=update@entry=0x0, cmpl_info=cmpl_info@entry=0, 
    rec=rec@entry=0x0, offsets=<optimized out>, roll_ptr=<optimized out>) at /data/Server/bb-11.2-MDEV-14795_1B/storage/innobase/include/trx0undo.inl:45
#1  0x00005648a5b34ac0 in row_ins_clust_index_entry_low (flags=flags@entry=0, mode=<optimized out>, mode@entry=BTR_MODIFY_LEAF, index=index@entry=0x616002b45008, n_uniq=n_uniq@entry=1, entry=entry@entry=0x61d00094a308, 
    n_ext=n_ext@entry=0, thr=<optimized out>) at /data/Server/bb-11.2-MDEV-14795_1B/storage/innobase/row/row0ins.cc:2772
#2  0x00005648a5b36265 in row_ins_clust_index_entry (index=index@entry=0x616002b45008, entry=entry@entry=0x61d00094a308, thr=thr@entry=0x6270000adbd0, n_ext=n_ext@entry=0)
    at /data/Server/bb-11.2-MDEV-14795_1B/storage/innobase/row/row0ins.cc:3243
#3  0x00005648a5b36e66 in row_ins_index_entry (index=0x616002b45008, entry=<optimized out>, thr=thr@entry=0x6270000adbd0) at /data/Server/bb-11.2-MDEV-14795_1B/storage/innobase/row/row0ins.cc:3375
#4  0x00005648a5b370b8 in row_ins_index_entry_step (node=node@entry=0x6270000ad080, thr=thr@entry=0x6270000adbd0) at /usr/include/c++/9/bits/stl_iterator.h:819
#5  0x00005648a5b3884a in row_ins (node=node@entry=0x6270000ad080, thr=thr@entry=0x6270000adbd0) at /data/Server/bb-11.2-MDEV-14795_1B/storage/innobase/row/row0ins.cc:3660
#6  0x00005648a5b3929c in row_ins_step (thr=thr@entry=0x6270000adbd0) at /data/Server/bb-11.2-MDEV-14795_1B/storage/innobase/row/row0ins.cc:3789
#7  0x00005648a5b90086 in row_insert_for_mysql (mysql_rec=mysql_rec@entry=0x6190001595e0 "\377\377\377\377\377\377\377\001", prebuilt=0x6270000ab988, ins_mode=<optimized out>)
    at /data/Server/bb-11.2-MDEV-14795_1B/storage/innobase/row/row0mysql.cc:1313
#8  0x00005648a57cc929 in ha_innobase::write_row (this=0x61d00013ceb8, record=<optimized out>) at /data/Server/bb-11.2-MDEV-14795_1B/storage/innobase/handler/ha_innodb.cc:7820
#9  0x00005648a4e5634f in handler::ha_write_row (this=0x61d00013ceb8, buf=0x6190001595e0 "\377\377\377\377\377\377\377\001") at /data/Server/bb-11.2-MDEV-14795_1B/sql/handler.cc:7802
#10 0x00005648a43e9d5e in write_record (thd=thd@entry=0x62b00015e218, table=table@entry=0x619000158698, info=info@entry=0x7efd2bd59eb0, sink=sink@entry=0x0) at /data/Server/bb-11.2-MDEV-14795_1B/sql/sql_insert.cc:2204
#11 0x00005648a440b294 in mysql_insert (thd=thd@entry=0x62b00015e218, table_list=<optimized out>, fields=..., values_list=..., update_fields=..., update_values=..., duplic=<optimized out>, ignore=<optimized out>, 
    result=<optimized out>) at /data/Server/bb-11.2-MDEV-14795_1B/sql/sql_insert.cc:1154
#12 0x00005648a44e161c in mysql_execute_command (thd=thd@entry=0x62b00015e218, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false) at /data/Server/bb-11.2-MDEV-14795_1B/sql/sql_parse.cc:4449
#13 0x00005648a44a178b in mysql_parse (thd=thd@entry=0x62b00015e218, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x7efd2bd5b130)
    at /data/Server/bb-11.2-MDEV-14795_1B/sql/sql_parse.cc:7774
#14 0x00005648a44d0705 in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x62b00015e218, 
    packet=packet@entry=0x629000d6b219 " INSERT INTO `table1_innodb_int_autoinc` ( `pk` ) VALUES ( @a )  /* E_R Thread1 QNO 1469 CON_ID 16 */ ", packet_length=packet_length@entry=102, blocking=blocking@entry=true)
    at /data/Server/bb-11.2-MDEV-14795_1B/sql/sql_class.h:1367
#15 0x00005648a44d7553 in do_command (thd=0x62b00015e218, blocking=blocking@entry=true) at /data/Server/bb-11.2-MDEV-14795_1B/sql/sql_parse.cc:1405
#16 0x00005648a497d30b in do_handle_one_connection (connect=<optimized out>, connect@entry=0x608000002b38, put_in_cache=put_in_cache@entry=true) at /data/Server/bb-11.2-MDEV-14795_1B/sql/sql_connect.cc:1416
#17 0x00005648a497de54 in handle_one_connection (arg=0x608000002b38) at /data/Server/bb-11.2-MDEV-14795_1B/sql/sql_connect.cc:1318
#18 0x00007efd59422609 in start_thread (arg=<optimized out>) at pthread_create.c:477
#19 0x00007efd58ff5293 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
(rr)
 
pluto:/data/results/1689088031/TBR-1997$ _RR_TRACE_DIR=./1/rr/ rr replay --mark-stdio
 
RQG
====
# git clone https://github.com/mleich1/rqg --branch <pick the right branch> RQG
#
# GIT_SHOW: HEAD -> master, origin/master, origin/HEAD d6a1d60ea930516cafe4e828751017641277f0d0 2023-07-11T16:45:15+02:00
# rqg.pl  : Version 4.3.0 (2023-06)
#
# $RQG_HOME/rqg.pl \
# --grammar=conf/replication/replication.yy \
# --gendata=conf/replication/replication-5.1.zz \
# --max_gd_duration=1200 \
# --mysqld=--innodb_data_file_path=ibdata1:1M:autoextend:autoshrink \
# --mysqld=--loose-innodb_lock_schedule_algorithm=fcfs \
# --mysqld=--loose-idle_write_transaction_timeout=0 \
# --mysqld=--loose-idle_transaction_timeout=0 \
# --mysqld=--loose-idle_readonly_transaction_timeout=0 \
# --mysqld=--connect_timeout=60 \
# --mysqld=--interactive_timeout=28800 \
# --mysqld=--slave_net_timeout=60 \
# --mysqld=--net_read_timeout=30 \
# --mysqld=--net_write_timeout=60 \
# --mysqld=--loose-table_lock_wait_timeout=50 \
# --mysqld=--wait_timeout=28800 \
# --no_mask \
# --queries=10000000 \
# --seed=random \
# --reporters=None \
# --reporters=ErrorLog \
# --reporters=Deadlock \
# --validators=None \
# --mysqld=--log_output=none \
# --mysqld=--log_bin_trust_function_creators=1 \
# --mysqld=--loose-debug_assert_on_not_freed_memory=0 \
# --engine=InnoDB \
# --restart_timeout=360 \
# --mysqld=--plugin-load-add=file_key_management.so \
# --mysqld=--loose-file-key-management-filename=$RQG_HOME/conf/mariadb/encryption_keys.txt \
# --mysqld=--plugin-load-add=provider_lzo.so \
# --mysqld=--plugin-load-add=provider_bzip2.so \
# --mysqld=--plugin-load-add=provider_lzma.so \
# --mysqld=--plugin-load-add=provider_snappy.so \
# --mysqld=--plugin-load-add=provider_lz4.so \
# --mysqld=--loose-innodb_compression_level=1 \
# --duration=300 \
# --mysqld=--loose-innodb_fatal_semaphore_wait_threshold=300 \
# --mysqld=--lock-wait-timeout=15 \
# --mysqld=--innodb-lock-wait-timeout=10 \
# --mysqld=--innodb_file_per_table=1 \
# --mysqld=--loose-innodb_read_only_compressed=OFF \
# --reporters=Mariabackup_linux \
# --duration=300 \
# --mysqld=--loose-innodb-sync-debug \
# --mysqld=--innodb_stats_persistent=off \
# --mysqld=--innodb_adaptive_hash_index=on \
# --mysqld=--innodb_sort_buffer_size=65536 \
# --mysqld=--innodb_random_read_ahead=OFF \
# --redefine=conf/mariadb/redefine_checks_off.yy \
# --mysqld=--loose-innodb_evict_tables_on_commit_debug=off \
# --mysqld=--loose-max-statement-time=30 \
# --threads=2 \
# --mysqld=--innodb-use-native-aio=0 \
# --mysqld=--loose-gdb \
# --mysqld=--loose-debug-gdb \
# --rr=Extended \
# --rr_options=--wait \
# --mysqld=--innodb_undo_log_truncate=OFF \
# --mysqld=--loose_innodb_change_buffering=purges \
# --mysqld=--innodb_undo_tablespaces=3 \
# --mysqld=--innodb_rollback_on_timeout=OFF \
# --mysqld=--innodb_page_size=32K \
# --mysqld=--innodb-buffer-pool-size=256M \
# --vardir_type=slow \
# <local settings>


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