Documentation at https://mariadb.com/kb/en/innodb-online-ddl-operations-with-the-instant-alter-algorithm/#alter-table-drop-index-and-drop-index states that 10.4 supports DROP INDEX ..., ALGORITHM=INSTANT, but it does not.
This is what I get when I run the example from that URL:
MariaDB [(none)]> \s
--------------
./bin/mysql Ver 15.1 Distrib 10.4.24-MariaDB, for Linux (x86_64) using readline 5.1
Connection id: 8
Current database:
Current user: bdempsey@localhost
SSL: Cipher in use is DHE-RSA-AES256-GCM-SHA384
Current pager: stdout
Using outfile: ''
Using delimiter: ;
Server: MariaDB
Server version: 10.4.24-MariaDB-debug Source distribution
Protocol version: 10
Connection: Localhost via UNIX socket
Server characterset: latin1
Db characterset: latin1
Client characterset: utf8
Conn. characterset: utf8
UNIX socket: /home/bdempsey/mariadb/10.2/data/mysql.sock
Uptime: 1 min 8 sec
Threads: 6 Questions: 4 Slow queries: 0 Opens: 17 Flush tables: 1 Open tables: 10 Queries per second avg: 0.058
--------------
MariaDB [foo]> CREATE OR REPLACE TABLE tab (
-> a int PRIMARY KEY,
-> b varchar(50),
-> c varchar(50),
-> INDEX b_index (b)
-> );
Query OK, 0 rows affected (0.053 sec)
MariaDB [foo]> SET SESSION alter_algorithm='INSTANT';
Query OK, 0 rows affected (0.000 sec)
MariaDB [foo]> ALTER TABLE tab DROP INDEX b_index;
ERROR 1846 (0A000): ALGORITHM=INSTANT is not supported. Reason: DROP INDEX. Try ALGORITHM=NOCOPY
Rob Schwyzer (Inactive)
made changes -
2022-03-17 19:57
Remote Link
This issue links to "Page (MariaDB Confluence)"
[ 33315
]
Elena Stepanova
made changes -
2022-04-17 16:44
Fix Version/s
N/A
[ 14700
]
Ian Gilfillan
made changes -
2022-05-10 20:48
Resolution
Fixed
[ 1
]
Status
Open
[ 1
]
Closed
[ 6
]
Jira Automation (IT)
made changes -
2024-07-04 01:40
Zendesk Related Tickets
201658
Zendesk active tickets
201658
{"report":{"fcp":828,"ttfb":181.5,"pageVisibility":"visible","entityId":108341,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":32,"apdex":1,"journeyId":"e627a3bb-0c5a-43cc-9670-7e82e95def16","navigationType":0,"readyForUser":921.6000003814697,"redirectCount":0,"resourceLoadedEnd":960.8999996185303,"resourceLoadedStart":187.30000019073486,"resourceTiming":[{"duration":46.09999942779541,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":187.30000019073486,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":187.30000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":233.39999961853027,"responseStart":0,"secureConnectionStart":0},{"duration":46,"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":187.60000038146973,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":187.60000038146973,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":233.60000038146973,"responseStart":0,"secureConnectionStart":0},{"duration":108.30000019073486,"initiatorType":"script","name":"https://jira.mariadb.org/s/0917945aaa57108d00c5076fea35e069-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":187.69999980926514,"connectEnd":187.69999980926514,"connectStart":187.69999980926514,"domainLookupEnd":187.69999980926514,"domainLookupStart":187.69999980926514,"fetchStart":187.69999980926514,"redirectEnd":0,"redirectStart":0,"requestStart":187.69999980926514,"responseEnd":296,"responseStart":296,"secureConnectionStart":187.69999980926514},{"duration":219.30000019073486,"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":187.89999961853027,"connectEnd":187.89999961853027,"connectStart":187.89999961853027,"domainLookupEnd":187.89999961853027,"domainLookupStart":187.89999961853027,"fetchStart":187.89999961853027,"redirectEnd":0,"redirectStart":0,"requestStart":187.89999961853027,"responseEnd":407.19999980926514,"responseStart":407.19999980926514,"secureConnectionStart":187.89999961853027},{"duration":222.9000005722046,"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":188.19999980926514,"connectEnd":188.19999980926514,"connectStart":188.19999980926514,"domainLookupEnd":188.19999980926514,"domainLookupStart":188.19999980926514,"fetchStart":188.19999980926514,"redirectEnd":0,"redirectStart":0,"requestStart":188.19999980926514,"responseEnd":411.1000003814697,"responseStart":411.1000003814697,"secureConnectionStart":188.19999980926514},{"duration":223.30000019073486,"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":188.30000019073486,"connectEnd":188.30000019073486,"connectStart":188.30000019073486,"domainLookupEnd":188.30000019073486,"domainLookupStart":188.30000019073486,"fetchStart":188.30000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":188.30000019073486,"responseEnd":411.6000003814697,"responseStart":411.6000003814697,"secureConnectionStart":188.30000019073486},{"duration":223.5,"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":188.5,"connectEnd":188.5,"connectStart":188.5,"domainLookupEnd":188.5,"domainLookupStart":188.5,"fetchStart":188.5,"redirectEnd":0,"redirectStart":0,"requestStart":188.5,"responseEnd":412,"responseStart":412,"secureConnectionStart":188.5},{"duration":252.5999994277954,"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":188.60000038146973,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":188.60000038146973,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":441.19999980926514,"responseStart":0,"secureConnectionStart":0},{"duration":224.30000019073486,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":188.80000019073486,"connectEnd":188.80000019073486,"connectStart":188.80000019073486,"domainLookupEnd":188.80000019073486,"domainLookupStart":188.80000019073486,"fetchStart":188.80000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":188.80000019073486,"responseEnd":413.1000003814697,"responseStart":413.1000003814697,"secureConnectionStart":188.80000019073486},{"duration":252.30000019073486,"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":189,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":189,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":441.30000019073486,"responseStart":0,"secureConnectionStart":0},{"duration":224.79999923706055,"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":189.10000038146973,"connectEnd":189.10000038146973,"connectStart":189.10000038146973,"domainLookupEnd":189.10000038146973,"domainLookupStart":189.10000038146973,"fetchStart":189.10000038146973,"redirectEnd":0,"redirectStart":0,"requestStart":189.10000038146973,"responseEnd":413.8999996185303,"responseStart":413.8999996185303,"secureConnectionStart":189.10000038146973},{"duration":488.0999994277954,"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":194.30000019073486,"connectEnd":194.30000019073486,"connectStart":194.30000019073486,"domainLookupEnd":194.30000019073486,"domainLookupStart":194.30000019073486,"fetchStart":194.30000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":194.30000019073486,"responseEnd":682.3999996185303,"responseStart":682.3999996185303,"secureConnectionStart":194.30000019073486},{"duration":731.8000001907349,"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":194.5,"connectEnd":194.5,"connectStart":194.5,"domainLookupEnd":194.5,"domainLookupStart":194.5,"fetchStart":194.5,"redirectEnd":0,"redirectStart":0,"requestStart":194.5,"responseEnd":926.3000001907349,"responseStart":926.3000001907349,"secureConnectionStart":194.5},{"duration":228.10000038146973,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":454.8999996185303,"connectEnd":454.8999996185303,"connectStart":454.8999996185303,"domainLookupEnd":454.8999996185303,"domainLookupStart":454.8999996185303,"fetchStart":454.8999996185303,"redirectEnd":0,"redirectStart":0,"requestStart":454.8999996185303,"responseEnd":683,"responseStart":683,"secureConnectionStart":454.8999996185303},{"duration":235.30000019073486,"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":725.3999996185303,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":725.3999996185303,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":960.6999998092651,"responseStart":0,"secureConnectionStart":0},{"duration":234.69999980926514,"initiatorType":"link","name":"https://jira.mariadb.org/s/50bc9be5bfead1a25e72c1a9338c94f6-CDN/lu2cib/820016/12ta74/e108c7645258ccb43280ed3404e3e949/_/download/contextbatch/css/com.atlassian.jira.plugins.jira-development-integration-plugin:0,-_super,-jira.view.issue,-jira.global,-jira.general,-jira.browse.project,-project.issue.navigator,-atl.general/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true&whisper-enabled=true","startTime":726.1999998092651,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":726.1999998092651,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":960.8999996185303,"responseStart":0,"secureConnectionStart":0}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":9,"responseStart":182,"responseEnd":187,"domLoading":186,"domInteractive":977,"domContentLoadedEventStart":977,"domContentLoadedEventEnd":1020,"domComplete":2472,"loadEventStart":2472,"loadEventEnd":2473,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":961.8999996185303},{"name":"bigPipe.sidebar-id.end","time":962.6999998092651},{"name":"bigPipe.activity-panel-pipe-id.start","time":962.8000001907349},{"name":"bigPipe.activity-panel-pipe-id.end","time":964.8000001907349},{"name":"activityTabFullyLoaded","time":1043.3999996185303}],"measures":[],"correlationId":"8f81111ac3ff6d","effectiveType":"4g","downlink":10,"rtt":0,"serverDuration":107,"dbReadsTimeInMs":16,"dbConnsTimeInMs":24,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}
Because DROP INDEX will take time proportional to the size of the index (to traverse not the index tree, but the linked list of allocated page numbers), it does not belong to the ALGORITHM=INSTANT subset of ALGORITHM=INPLACE. It is allowed by ALGORITHM=NOCOPY.
The unfortunately named ALGORITHM=INPLACE allows the table to be rebuilt (copied), while ALGORITHM=NOCOPY does not allow that. A name like ALGORITHM=ENGINE would have been more appropriate for the generic native ALTER TABLE.