Note: It's a continuation of MDEV-13475 and is probably a side-effect of it; but I want to have the assertion failure filed for the record, to have it searchable.
After the scenario in MDEV-13475 is executed and the failure described there occurs, start the server again, now without innodb-read-only (it starts all right), and try to execute some DML on a table, e.g. INSERT INTO t1 VALUES (2) on the datadir attached to MDEV-13475.
#7 0x00007f142f09aee2 in __assert_fail () from /lib/x86_64-linux-gnu/libc.so.6
#8 0x000056167a37e241 in trx_undo_page_report_insert (undo_page=0x7f140c050000 "\245K", <incomplete sequence \350>, trx=0x7f14198ddca8, index=0x7f13c0029fe8, clust_entry=0x7f13c0007eb8, mtr=0x7f14198d8580) at /data/src/bb-10.3-monty/storage/innobase/trx/trx0rec.cc:472
#9 0x000056167a381be0 in trx_undo_report_row_operation (thr=0x7f13c0021500, index=0x7f13c0029fe8, clust_entry=0x7f13c0007eb8, update=0x0, cmpl_info=0, rec=0x0, offsets=0x0, roll_ptr=0x7f14198d8b30) at /data/src/bb-10.3-monty/storage/innobase/trx/trx0rec.cc:1933
#10 0x000056167a3d6c76 in btr_cur_ins_lock_and_undo (flags=0, cursor=0x7f14198d8fe0, entry=0x7f13c0007eb8, thr=0x7f13c0021500, mtr=0x7f14198d9400, inherit=0x7f14198d8bc0) at /data/src/bb-10.3-monty/storage/innobase/btr/btr0cur.cc:2827
#11 0x000056167a3d75b6 in btr_cur_optimistic_insert (flags=0, cursor=0x7f14198d8fe0, offsets=0x7f14198d8f80, heap=0x7f14198d8f78, entry=0x7f13c0007eb8, rec=0x7f14198d8f88, big_rec=0x7f14198d8f70, n_ext=0, thr=0x7f13c0021500, mtr=0x7f14198d9400) at /data/src/bb-10.3-monty/storage/innobase/btr/btr0cur.cc:3040
#12 0x000056167a2aee25 in row_ins_clust_index_entry_low (flags=0, mode=2, index=0x7f13c0029fe8, n_uniq=0, entry=0x7f13c0007eb8, n_ext=0, thr=0x7f13c0021500, dup_chk_only=false) at /data/src/bb-10.3-monty/storage/innobase/row/row0ins.cc:2719
#13 0x000056167a2b04c5 in row_ins_clust_index_entry (index=0x7f13c0029fe8, entry=0x7f13c0007eb8, thr=0x7f13c0021500, n_ext=0, dup_chk_only=false) at /data/src/bb-10.3-monty/storage/innobase/row/row0ins.cc:3215
#14 0x000056167a2b088f in row_ins_index_entry (index=0x7f13c0029fe8, entry=0x7f13c0007eb8, thr=0x7f13c0021500) at /data/src/bb-10.3-monty/storage/innobase/row/row0ins.cc:3322
#15 0x000056167a2b0da1 in row_ins_index_entry_step (node=0x7f13c00212a8, thr=0x7f13c0021500) at /data/src/bb-10.3-monty/storage/innobase/row/row0ins.cc:3472
#16 0x000056167a2b1160 in row_ins (node=0x7f13c00212a8, thr=0x7f13c0021500) at /data/src/bb-10.3-monty/storage/innobase/row/row0ins.cc:3614
#17 0x000056167a2b18f5 in row_ins_step (thr=0x7f13c0021500) at /data/src/bb-10.3-monty/storage/innobase/row/row0ins.cc:3818
#18 0x000056167a2cf529 in row_insert_for_mysql (mysql_rec=0x7f13c000e708 "\375\002", prebuilt=0x7f13c0020af8) at /data/src/bb-10.3-monty/storage/innobase/row/row0mysql.cc:1484
#19 0x000056167a18e816 in ha_innobase::write_row (this=0x7f13c0020308, record=0x7f13c000e708 "\375\002") at /data/src/bb-10.3-monty/storage/innobase/handler/ha_innodb.cc:8444
#20 0x0000561679e83680 in handler::ha_write_row (this=0x7f13c0020308, buf=0x7f13c000e708 "\375\002") at /data/src/bb-10.3-monty/sql/handler.cc:5982
#21 0x0000561679b9c009 in write_record (thd=0x7f13c0000b00, table=0x7f13c001f700, info=0x7f14198da200) at /data/src/bb-10.3-monty/sql/sql_insert.cc:1929
#22 0x0000561679b99a8b in mysql_insert (thd=0x7f13c0000b00, table_list=0x7f13c0013528, fields=..., values_list=..., update_fields=..., update_values=..., duplic=DUP_ERROR, ignore=false) at /data/src/bb-10.3-monty/sql/sql_insert.cc:1057
#23 0x0000561679bcafcc in mysql_execute_command (thd=0x7f13c0000b00) at /data/src/bb-10.3-monty/sql/sql_parse.cc:4621
#24 0x0000561679bd56b6 in mysql_parse (thd=0x7f13c0000b00, rawbuf=0x7f13c0013448 "insert into t1 values (2)", length=25, parser_state=0x7f14198db660, is_com_multi=false, is_next_command=false) at /data/src/bb-10.3-monty/sql/sql_parse.cc:7919
#25 0x0000561679bc383f in dispatch_command (command=COM_QUERY, thd=0x7f13c0000b00, packet=0x7f13c001a571 "insert into t1 values (2)", packet_length=25, is_com_multi=false, is_next_command=false) at /data/src/bb-10.3-monty/sql/sql_parse.cc:1829
#26 0x0000561679bc22e1 in do_command (thd=0x7f13c0000b00) at /data/src/bb-10.3-monty/sql/sql_parse.cc:1380
#27 0x0000561679d115cc in do_handle_one_connection (connect=0x56167dc22240) at /data/src/bb-10.3-monty/sql/sql_connect.cc:1354
#28 0x0000561679d11359 in handle_one_connection (arg=0x56167dc22240) at /data/src/bb-10.3-monty/sql/sql_connect.cc:1260
#29 0x00007f1430fdf494 in start_thread (arg=0x7f14198dc700) at pthread_create.c:333
#30 0x00007f142f15793f in clone () from /lib/x86_64-linux-gnu/libc.so.6
Attachments
Issue Links
is caused by
MDEV-12288Reset DB_TRX_ID when the history is removed, to speed up MVCC
After relaxing the too-strict debug assertions on TRX_UNDO_PAGE_TYPE, I tested with the following:
--source include/have_innodb.inc
SELECT * FROM t1;
BEGIN;
INSERTINTO t1 VALUES (2);
DELETEFROM t1;
ROLLBACK;
SELECT * FROM t1;
./mtr --manual-gdb main.dml
show args
run [args copied from the output of the above] --datadir /path/to/data
These are too strict debug assertions. When undo logs pre-exist, the page types could be 1 (for insert_undo) or 2 (update_undo), instead of the new unified page type 0 that was introduced in MDEV-12288.
Marko Mäkelä
added a comment - After relaxing the too-strict debug assertions on TRX_UNDO_PAGE_TYPE, I tested with the following:
--source include/have_innodb.inc
SELECT * FROM t1;
BEGIN ;
INSERT INTO t1 VALUES (2);
DELETE FROM t1;
ROLLBACK ;
SELECT * FROM t1;
./mtr --manual-gdb main.dml
show args
run [args copied from the output of the above] --datadir /path/to/data
These are too strict debug assertions. When undo logs pre-exist, the page types could be 1 (for insert_undo) or 2 (update_undo), instead of the new unified page type 0 that was introduced in MDEV-12288 .
People
Marko Mäkelä
Elena Stepanova
Votes:
0Vote for this issue
Watchers:
2Start watching this issue
Dates
Created:
Updated:
Resolved:
Git Integration
Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.
{"report":{"fcp":1016.1000003814697,"ttfb":341.30000019073486,"pageVisibility":"visible","entityId":62546,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":0.5,"journeyId":"a7947edd-07fb-497d-ad23-188fc2b7a02e","navigationType":0,"readyForUser":1131.9000000953674,"redirectCount":0,"resourceLoadedEnd":1267.2000002861023,"resourceLoadedStart":348.1000003814697,"resourceTiming":[{"duration":112.09999990463257,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":348.1000003814697,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":348.1000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":460.2000002861023,"responseStart":0,"secureConnectionStart":0},{"duration":112.30000019073486,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2cib/820016/12ta74/494e4c556ecbb29f90a3d3b4f09cb99c/_/download/contextbatch/css/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true&whisper-enabled=true","startTime":348.40000009536743,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":348.40000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":460.7000002861023,"responseStart":0,"secureConnectionStart":0},{"duration":121.10000038146973,"initiatorType":"script","name":"https://jira.mariadb.org/s/0917945aaa57108d00c5076fea35e069-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":348.5,"connectEnd":348.5,"connectStart":348.5,"domainLookupEnd":348.5,"domainLookupStart":348.5,"fetchStart":348.5,"redirectEnd":0,"redirectStart":0,"requestStart":348.5,"responseEnd":469.6000003814697,"responseStart":469.6000003814697,"secureConnectionStart":348.5},{"duration":242.7999997138977,"initiatorType":"script","name":"https://jira.mariadb.org/s/2d8175ec2fa4c816e8023260bd8c1786-CDN/lu2cib/820016/12ta74/494e4c556ecbb29f90a3d3b4f09cb99c/_/download/contextbatch/js/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true&whisper-enabled=true","startTime":348.7000002861023,"connectEnd":348.7000002861023,"connectStart":348.7000002861023,"domainLookupEnd":348.7000002861023,"domainLookupStart":348.7000002861023,"fetchStart":348.7000002861023,"redirectEnd":0,"redirectStart":0,"requestStart":348.7000002861023,"responseEnd":591.5,"responseStart":591.5,"secureConnectionStart":348.7000002861023},{"duration":230.7999997138977,"initiatorType":"script","name":"https://jira.mariadb.org/s/a9324d6758d385eb45c462685ad88f1d-CDN/lu2cib/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":364.1000003814697,"connectEnd":364.1000003814697,"connectStart":364.1000003814697,"domainLookupEnd":364.1000003814697,"domainLookupStart":364.1000003814697,"fetchStart":364.1000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":364.1000003814697,"responseEnd":594.9000000953674,"responseStart":594.9000000953674,"secureConnectionStart":364.1000003814697},{"duration":231.09999990463257,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":364.30000019073486,"connectEnd":364.30000019073486,"connectStart":364.30000019073486,"domainLookupEnd":364.30000019073486,"domainLookupStart":364.30000019073486,"fetchStart":364.30000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":364.30000019073486,"responseEnd":595.4000000953674,"responseStart":595.4000000953674,"secureConnectionStart":364.30000019073486},{"duration":231,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":364.7000002861023,"connectEnd":364.7000002861023,"connectStart":364.7000002861023,"domainLookupEnd":364.7000002861023,"domainLookupStart":364.7000002861023,"fetchStart":364.7000002861023,"redirectEnd":0,"redirectStart":0,"requestStart":364.7000002861023,"responseEnd":595.7000002861023,"responseStart":595.7000002861023,"secureConnectionStart":364.7000002861023},{"duration":252.80000019073486,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2cib/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":364.90000009536743,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":364.90000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":617.7000002861023,"responseStart":0,"secureConnectionStart":0},{"duration":231.09999990463257,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":365.1000003814697,"connectEnd":365.1000003814697,"connectStart":365.1000003814697,"domainLookupEnd":365.1000003814697,"domainLookupStart":365.1000003814697,"fetchStart":365.1000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":365.1000003814697,"responseEnd":596.2000002861023,"responseStart":596.2000002861023,"secureConnectionStart":365.1000003814697},{"duration":252.5,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2cib/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/css/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.css?jira.create.linked.issue=true","startTime":365.30000019073486,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":365.30000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":617.8000001907349,"responseStart":0,"secureConnectionStart":0},{"duration":231.30000019073486,"initiatorType":"script","name":"https://jira.mariadb.org/s/5d5e8fe91fbc506585e83ea3b62ccc4b-CDN/lu2cib/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/js/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.js?jira.create.linked.issue=true&locale=en","startTime":365.40000009536743,"connectEnd":365.40000009536743,"connectStart":365.40000009536743,"domainLookupEnd":365.40000009536743,"domainLookupStart":365.40000009536743,"fetchStart":365.40000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":365.40000009536743,"responseEnd":596.7000002861023,"responseStart":596.7000002861023,"secureConnectionStart":365.40000009536743},{"duration":466.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":366.5,"connectEnd":366.5,"connectStart":366.5,"domainLookupEnd":366.5,"domainLookupStart":366.5,"fetchStart":366.5,"redirectEnd":0,"redirectStart":0,"requestStart":366.5,"responseEnd":833,"responseStart":833,"secureConnectionStart":366.5},{"duration":842.8999996185303,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":366.6000003814697,"connectEnd":366.6000003814697,"connectStart":366.6000003814697,"domainLookupEnd":366.6000003814697,"domainLookupStart":366.6000003814697,"fetchStart":366.6000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":366.6000003814697,"responseEnd":1209.5,"responseStart":1209.5,"secureConnectionStart":366.6000003814697},{"duration":222.7000002861023,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":630.4000000953674,"connectEnd":630.4000000953674,"connectStart":630.4000000953674,"domainLookupEnd":630.4000000953674,"domainLookupStart":630.4000000953674,"fetchStart":630.4000000953674,"redirectEnd":0,"redirectStart":0,"requestStart":630.4000000953674,"responseEnd":853.1000003814697,"responseStart":853.1000003814697,"secureConnectionStart":630.4000000953674},{"duration":346.19999980926514,"initiatorType":"link","name":"https://jira.mariadb.org/s/d5715adaadd168a9002b108b2b039b50-CDN/lu2cib/820016/12ta74/be4b45e9cec53099498fa61c8b7acba4/_/download/contextbatch/css/jira.project.sidebar,-_super,-project.issue.navigator,-jira.general,-jira.browse.project,-jira.view.issue,-jira.global,-atl.general,-com.atlassian.jira.projects.sidebar.init/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true&whisper-enabled=true","startTime":917.1000003814697,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":917.1000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1263.3000001907349,"responseStart":0,"secureConnectionStart":0},{"duration":322.1000003814697,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/e65b778d185daf5aee24936755b43da6/_/download/contextbatch/js/browser-metrics-plugin.contrib,-_super,-project.issue.navigator,-jira.view.issue,-atl.general/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true&whisper-enabled=true","startTime":918,"connectEnd":918,"connectStart":918,"domainLookupEnd":918,"domainLookupStart":918,"fetchStart":918,"redirectEnd":0,"redirectStart":0,"requestStart":918,"responseEnd":1240.1000003814697,"responseStart":1240.1000003814697,"secureConnectionStart":918},{"duration":348.7000002861023,"initiatorType":"script","name":"https://jira.mariadb.org/s/097ae97cb8fbec7d6ea4bbb1f26955b9-CDN/lu2cib/820016/12ta74/be4b45e9cec53099498fa61c8b7acba4/_/download/contextbatch/js/jira.project.sidebar,-_super,-project.issue.navigator,-jira.general,-jira.browse.project,-jira.view.issue,-jira.global,-atl.general,-com.atlassian.jira.projects.sidebar.init/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true&whisper-enabled=true","startTime":918.5,"connectEnd":918.5,"connectStart":918.5,"domainLookupEnd":918.5,"domainLookupStart":918.5,"fetchStart":918.5,"redirectEnd":0,"redirectStart":0,"requestStart":918.5,"responseEnd":1267.2000002861023,"responseStart":1267.1000003814697,"secureConnectionStart":918.5}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":173,"responseStart":341,"responseEnd":345,"domLoading":345,"domInteractive":1281,"domContentLoadedEventStart":1281,"domContentLoadedEventEnd":1342,"domComplete":1714,"loadEventStart":1714,"loadEventEnd":1715,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":1211.2000002861023},{"name":"bigPipe.sidebar-id.end","time":1212.1000003814697},{"name":"bigPipe.activity-panel-pipe-id.start","time":1212.3000001907349},{"name":"bigPipe.activity-panel-pipe-id.end","time":1213.6000003814697},{"name":"activityTabFullyLoaded","time":1356.9000000953674}],"measures":[],"correlationId":"1547188cc09851","effectiveType":"4g","downlink":10,"rtt":0,"serverDuration":105,"dbReadsTimeInMs":16,"dbConnsTimeInMs":26,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}
After relaxing the too-strict debug assertions on TRX_UNDO_PAGE_TYPE, I tested with the following:
--source include/have_innodb.inc
./mtr --manual-gdb main.dml
show args
run [args copied from the output of the above] --datadir /path/to/data
These are too strict debug assertions. When undo logs pre-exist, the page types could be 1 (for insert_undo) or 2 (update_undo), instead of the new unified page type 0 that was introduced in
MDEV-12288.