parts.partition_debug fails with 2 warnings "Table: ./test/t1#P#p2 is open on rename new table2"
This happens only in 10.7 (I could not repeat it with 10.6) when compiled with DBUG
I can repeat it to 100% on my desktop.
parts.partition_debug [ fail ] Found warnings/errors in server log file!
Test ended at 2022-01-24 15:59:58
line
Warning: Table: ./test/t1#P#p2 is open on rename new table2
Warning: Table: ./test/t1#P#p2 is open on rename new table2
A shorter test case, just for debugging:
(The normal test case, parts.partition_debug only needs to be extended with this MDEV number). Note that it is the new code for CONVERT PARTITION that is generating the issue.
As a separate issue, I noticed that the code does try to rename files that does not exists:
error: error: 7 message: 'Error on rename of './test/tp2.MYD' to './test/t1#P#p2.MYD' (Errcode: 2 "No such file or directory")
That code could probably be cleaned up so that we don't generate errors/warnings that are not needed (for example by testing if the file exists or not before doing a rename)
# including crashing tests.
|
|
--source include/have_debug.inc
|
--source include/have_partition.inc
|
# Don't test this under valgrind, memory leaks will occur
|
--source include/not_valgrind.inc
|
# Crash tests don't work with embedded
|
--source include/not_embedded.inc
|
|
# Make sure system tables are not open, as the test will kill the server
|
# and it will cause corruption errors in the log
|
FLUSH TABLES;
|
|
--echo #
|
--echo # MDEV-22166 CONVERT PARTITION: move out partition into a table
|
--echo #
|
let $create_statement= create or replace table t1 (x int primary key)
|
partition by range(x) (
|
partition p1 values less than (10),
|
partition p2 values less than (20),
|
partition p3 values less than (30),
|
partition p4 values less than (40),
|
partition p5 values less than (50),
|
partition pn values less than maxvalue);
|
|
let $insert_statement= insert into t1 values (2), (12), (22), (32), (42), (52);
|
let $fail_statement= alter table t1 convert partition p2 to table tp2;
|
|
set @save_dbug=@@debug_dbug;
|
set session debug_dbug="+d,fail_convert_partition_5";
|
--source suite/parts/inc/partition_fail.inc
|
set session debug_dbug=@save_dbug;
|
set session debug_dbug="+d,fail_convert_partition_11";
|
--echo # Already finished DDL logging, so tp2 now exists:
|
--source suite/parts/inc/partition_fail.inc
|
set session debug_dbug=@save_dbug;
|
show create table tp2;
|
select * from tp2;
|
drop table tp2;
|
{"report":{"fcp":735.1999998092651,"ttfb":164.30000019073486,"pageVisibility":"visible","entityId":107114,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":1,"journeyId":"961b85fb-e436-44db-9e2d-9b41e0b11c0a","navigationType":0,"readyForUser":811.3000001907349,"redirectCount":0,"resourceLoadedEnd":773.5,"resourceLoadedStart":172.19999980926514,"resourceTiming":[{"duration":8.300000190734863,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":172.19999980926514,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":172.19999980926514,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":180.5,"responseStart":0,"secureConnectionStart":0},{"duration":8.300000190734863,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2cib/820016/12ta74/2bf333562ca6724060a9d5f1535471f6/_/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","startTime":172.5,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":172.5,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":180.80000019073486,"responseStart":0,"secureConnectionStart":0},{"duration":61.80000019073486,"initiatorType":"script","name":"https://jira.mariadb.org/s/0917945aaa57108d00c5076fea35e069-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":172.69999980926514,"connectEnd":172.69999980926514,"connectStart":172.69999980926514,"domainLookupEnd":172.69999980926514,"domainLookupStart":172.69999980926514,"fetchStart":172.69999980926514,"redirectEnd":0,"redirectStart":0,"requestStart":172.69999980926514,"responseEnd":234.5,"responseStart":234.5,"secureConnectionStart":172.69999980926514},{"duration":196.19999980926514,"initiatorType":"script","name":"https://jira.mariadb.org/s/2d8175ec2fa4c816e8023260bd8c1786-CDN/lu2cib/820016/12ta74/2bf333562ca6724060a9d5f1535471f6/_/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","startTime":172.80000019073486,"connectEnd":172.80000019073486,"connectStart":172.80000019073486,"domainLookupEnd":172.80000019073486,"domainLookupStart":172.80000019073486,"fetchStart":172.80000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":172.80000019073486,"responseEnd":369,"responseStart":369,"secureConnectionStart":172.80000019073486},{"duration":199.5999994277954,"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":173.10000038146973,"connectEnd":173.10000038146973,"connectStart":173.10000038146973,"domainLookupEnd":173.10000038146973,"domainLookupStart":173.10000038146973,"fetchStart":173.10000038146973,"redirectEnd":0,"redirectStart":0,"requestStart":173.10000038146973,"responseEnd":372.69999980926514,"responseStart":372.69999980926514,"secureConnectionStart":173.10000038146973},{"duration":200.10000038146973,"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":173.19999980926514,"connectEnd":173.19999980926514,"connectStart":173.19999980926514,"domainLookupEnd":173.19999980926514,"domainLookupStart":173.19999980926514,"fetchStart":173.19999980926514,"redirectEnd":0,"redirectStart":0,"requestStart":173.19999980926514,"responseEnd":373.30000019073486,"responseStart":373.30000019073486,"secureConnectionStart":173.19999980926514},{"duration":200.19999980926514,"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":173.5,"connectEnd":173.5,"connectStart":173.5,"domainLookupEnd":173.5,"domainLookupStart":173.5,"fetchStart":173.5,"redirectEnd":0,"redirectStart":0,"requestStart":173.5,"responseEnd":373.69999980926514,"responseStart":373.69999980926514,"secureConnectionStart":173.5},{"duration":207.4000005722046,"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":173.69999980926514,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":173.69999980926514,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":381.1000003814697,"responseStart":0,"secureConnectionStart":0},{"duration":201.5,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":173.80000019073486,"connectEnd":173.80000019073486,"connectStart":173.80000019073486,"domainLookupEnd":173.80000019073486,"domainLookupStart":173.80000019073486,"fetchStart":173.80000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":173.80000019073486,"responseEnd":375.30000019073486,"responseStart":375.30000019073486,"secureConnectionStart":173.80000019073486},{"duration":207.19999980926514,"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":174,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":174,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":381.19999980926514,"responseStart":0,"secureConnectionStart":0},{"duration":202.89999961853027,"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":174.10000038146973,"connectEnd":174.10000038146973,"connectStart":174.10000038146973,"domainLookupEnd":174.10000038146973,"domainLookupStart":174.10000038146973,"fetchStart":174.10000038146973,"redirectEnd":0,"redirectStart":0,"requestStart":174.10000038146973,"responseEnd":377,"responseStart":377,"secureConnectionStart":174.10000038146973},{"duration":262.20000076293945,"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":174.89999961853027,"connectEnd":174.89999961853027,"connectStart":174.89999961853027,"domainLookupEnd":174.89999961853027,"domainLookupStart":174.89999961853027,"fetchStart":174.89999961853027,"redirectEnd":0,"redirectStart":0,"requestStart":174.89999961853027,"responseEnd":437.1000003814697,"responseStart":437.1000003814697,"secureConnectionStart":174.89999961853027},{"duration":291.1000003814697,"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":175,"connectEnd":175,"connectStart":175,"domainLookupEnd":175,"domainLookupStart":175,"fetchStart":175,"redirectEnd":0,"redirectStart":0,"requestStart":175,"responseEnd":466.1000003814697,"responseStart":466.1000003814697,"secureConnectionStart":175},{"duration":45.69999980926514,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":393,"connectEnd":393,"connectStart":393,"domainLookupEnd":393,"domainLookupStart":393,"fetchStart":393,"redirectEnd":0,"redirectStart":0,"requestStart":393,"responseEnd":438.69999980926514,"responseStart":438.69999980926514,"secureConnectionStart":393},{"duration":330.5,"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","startTime":443,"connectEnd":443,"connectStart":443,"domainLookupEnd":443,"domainLookupStart":443,"fetchStart":443,"redirectEnd":0,"redirectStart":0,"requestStart":443,"responseEnd":773.5,"responseStart":773.5,"secureConnectionStart":443},{"duration":117.20000076293945,"initiatorType":"script","name":"https://www.google-analytics.com/analytics.js","startTime":728.3999996185303,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":728.3999996185303,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":845.6000003814697,"responseStart":0,"secureConnectionStart":0}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":4,"responseStart":164,"responseEnd":166,"domLoading":168,"domInteractive":871,"domContentLoadedEventStart":871,"domContentLoadedEventEnd":916,"domComplete":1234,"loadEventStart":1234,"loadEventEnd":1234,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":847.3000001907349},{"name":"bigPipe.sidebar-id.end","time":848.3000001907349},{"name":"bigPipe.activity-panel-pipe-id.start","time":848.3999996185303},{"name":"bigPipe.activity-panel-pipe-id.end","time":850.8999996185303},{"name":"activityTabFullyLoaded","time":927.1000003814697}],"measures":[],"correlationId":"90131f0ac8aa6c","effectiveType":"4g","downlink":10,"rtt":0,"serverDuration":93,"dbReadsTimeInMs":9,"dbConnsTimeInMs":17,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}