Hi Guys,
we'll be updating in company SQL software, and i benchmarked several recent versions of mysql. Basically thanks to some optimizer / internal changes it seems that recent mariadb is like 10 times faster than mysql5.6 and percona in some cases. Also it seems to work better than recent mysql 5.7...
But in some queries i see that 90% of time is wasted copying to temp tables.
Now there could be some errors in documentation, as far as i understand, increasing aria_pagecache_buffer_size should result in no disk writes, but it doesn't make any difference.
So i played with configuration a little, it seems that increasing
max_heap_table_size = 1024M
tmp_table_size = 1024M
+ setting aria page size to 1KB
Is improving things a lot, run time gets cut by half to about 4 seconds. So maybe docs need to be updated...
The problem is that out of the box, with "default" heap / tmp table settings mysql 5.7 is much faster 5-6s instead of 8-9s (mariadb 10.1.8). I compiled the server from sources disabling ARIA as TMP engine, and it resulted in run times close to 4-5s. So it was faster than mysql. After changing tmp table settings as above it went to 3s.
Out of the box: 8s
Optimized: 5s;
TMP engine changed to myisam+optimized: 3s
So im filling it as major bug as having maria as default storage angine for TMP tables seem to degrade performance a lot. Honestly i wasn't able to find queries where it'll improve things. In DOC it says that table scans are faster over myisam than aria. Is there a reason to keep it as default engine and removing ability to set it in server config without compiling from sources?
In docs it says that doing full table scans it's slower for PAGE (which seems true). Maybe it'd be good to have more control over it, eg. maybe using ROW_FORMAT=Dynamic for all internal aria temporary tables would make aria on par with myisam for internal tmp tables? Maybe just queries im doing don't play nicely with aria, any suggestions?
It seems that not being able to fully control how internal tmp tables behave is having big performance impact.
Thanks.
Attachments
Issue Links
relates to
MDEV-8132Temporary Tables using Aria with very poor performance
After two years MariaDB start checking an easy to reproduce problem and it seems that it will take 2 more years for a fix
Dimitris Chatzis
added a comment - After two years MariaDB start checking an easy to reproduce problem and it seems that it will take 2 more years for a fix
Fixed performance problem with Aria by speeding up find_head().
The result of this patch is a up to 2x or more speed up for inserts without keys for
format PAGE.
Michael Widenius
added a comment - Fixed performance problem with Aria by speeding up find_head().
The result of this patch is a up to 2x or more speed up for inserts without keys for
format PAGE.
People
Michael Widenius
Slawomir Pryczek
Votes:
2Vote for this issue
Watchers:
8Start 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":813.6000000238419,"ttfb":217.20000004768372,"pageVisibility":"visible","entityId":54040,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":1,"journeyId":"e21d375d-9980-4a50-925d-12b19bcfb5cf","navigationType":0,"readyForUser":888.3999999761581,"redirectCount":0,"resourceLoadedEnd":770.7999999523163,"resourceLoadedStart":222.39999997615814,"resourceTiming":[{"duration":42.200000047683716,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2bu7/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":222.39999997615814,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":222.39999997615814,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":264.60000002384186,"responseStart":0,"secureConnectionStart":0},{"duration":42.39999997615814,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2bu7/820016/12ta74/8679b4946efa1a0bb029a3a22206fb5d/_/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":222.60000002384186,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":222.60000002384186,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":265,"responseStart":0,"secureConnectionStart":0},{"duration":98.80000007152557,"initiatorType":"script","name":"https://jira.mariadb.org/s/fbf975c0cce4b1abf04784eeae9ba1f4-CDN/lu2bu7/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":222.79999995231628,"connectEnd":222.79999995231628,"connectStart":222.79999995231628,"domainLookupEnd":222.79999995231628,"domainLookupStart":222.79999995231628,"fetchStart":222.79999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":222.79999995231628,"responseEnd":321.60000002384186,"responseStart":321.60000002384186,"secureConnectionStart":222.79999995231628},{"duration":174.29999995231628,"initiatorType":"script","name":"https://jira.mariadb.org/s/099b33461394b8015fc36c0a4b96e19f-CDN/lu2bu7/820016/12ta74/8679b4946efa1a0bb029a3a22206fb5d/_/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":223,"connectEnd":223,"connectStart":223,"domainLookupEnd":223,"domainLookupStart":223,"fetchStart":223,"redirectEnd":0,"redirectStart":0,"requestStart":223,"responseEnd":397.2999999523163,"responseStart":397.2999999523163,"secureConnectionStart":223},{"duration":178,"initiatorType":"script","name":"https://jira.mariadb.org/s/94c15bff32baef80f4096a08aceae8bc-CDN/lu2bu7/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":223.20000004768372,"connectEnd":223.20000004768372,"connectStart":223.20000004768372,"domainLookupEnd":223.20000004768372,"domainLookupStart":223.20000004768372,"fetchStart":223.20000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":223.20000004768372,"responseEnd":401.2000000476837,"responseStart":401.2000000476837,"secureConnectionStart":223.20000004768372},{"duration":178.40000009536743,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":223.29999995231628,"connectEnd":223.29999995231628,"connectStart":223.29999995231628,"domainLookupEnd":223.29999995231628,"domainLookupStart":223.29999995231628,"fetchStart":223.29999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":223.29999995231628,"responseEnd":401.7000000476837,"responseStart":401.7000000476837,"secureConnectionStart":223.29999995231628},{"duration":178.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":223.5,"connectEnd":223.5,"connectStart":223.5,"domainLookupEnd":223.5,"domainLookupStart":223.5,"fetchStart":223.5,"redirectEnd":0,"redirectStart":0,"requestStart":223.5,"responseEnd":402,"responseStart":402,"secureConnectionStart":223.5},{"duration":239.5,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2bu7/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":223.70000004768372,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":223.70000004768372,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":463.2000000476837,"responseStart":0,"secureConnectionStart":0},{"duration":178.60000002384186,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":223.79999995231628,"connectEnd":223.79999995231628,"connectStart":223.79999995231628,"domainLookupEnd":223.79999995231628,"domainLookupStart":223.79999995231628,"fetchStart":223.79999995231628,"redirectEnd":0,"redirectStart":0,"requestStart":223.79999995231628,"responseEnd":402.39999997615814,"responseStart":402.39999997615814,"secureConnectionStart":223.79999995231628},{"duration":239.30000007152557,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2bu7/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":223.89999997615814,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":223.89999997615814,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":463.2000000476837,"responseStart":0,"secureConnectionStart":0},{"duration":178.89999997615814,"initiatorType":"script","name":"https://jira.mariadb.org/s/3339d87fa2538a859872f2df449bf8d0-CDN/lu2bu7/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":224.10000002384186,"connectEnd":224.10000002384186,"connectStart":224.10000002384186,"domainLookupEnd":224.10000002384186,"domainLookupStart":224.10000002384186,"fetchStart":224.10000002384186,"redirectEnd":0,"redirectStart":0,"requestStart":224.10000002384186,"responseEnd":403,"responseStart":402.89999997615814,"secureConnectionStart":224.10000002384186},{"duration":307.7000000476837,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":224.89999997615814,"connectEnd":224.89999997615814,"connectStart":224.89999997615814,"domainLookupEnd":224.89999997615814,"domainLookupStart":224.89999997615814,"fetchStart":224.89999997615814,"redirectEnd":0,"redirectStart":0,"requestStart":224.89999997615814,"responseEnd":532.6000000238419,"responseStart":532.6000000238419,"secureConnectionStart":224.89999997615814},{"duration":338.60000002384186,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bu7/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":225,"connectEnd":225,"connectStart":225,"domainLookupEnd":225,"domainLookupStart":225,"fetchStart":225,"redirectEnd":0,"redirectStart":0,"requestStart":225,"responseEnd":563.6000000238419,"responseStart":563.6000000238419,"secureConnectionStart":225},{"duration":69.40000009536743,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":490.2999999523163,"connectEnd":490.2999999523163,"connectStart":490.2999999523163,"domainLookupEnd":490.2999999523163,"domainLookupStart":490.2999999523163,"fetchStart":490.2999999523163,"redirectEnd":0,"redirectStart":0,"requestStart":490.2999999523163,"responseEnd":559.7000000476837,"responseStart":559.7000000476837,"secureConnectionStart":490.2999999523163},{"duration":39.09999990463257,"initiatorType":"link","name":"https://jira.mariadb.org/s/d5715adaadd168a9002b108b2b039b50-CDN/lu2bu7/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","startTime":731.7000000476837,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":731.7000000476837,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":770.7999999523163,"responseStart":0,"secureConnectionStart":0}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":53,"responseStart":217,"responseEnd":220,"domLoading":220,"domInteractive":937,"domContentLoadedEventStart":937,"domContentLoadedEventEnd":983,"domComplete":1236,"loadEventStart":1237,"loadEventEnd":1237,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":918.7999999523163},{"name":"bigPipe.sidebar-id.end","time":919.6000000238419},{"name":"bigPipe.activity-panel-pipe-id.start","time":919.7000000476837},{"name":"bigPipe.activity-panel-pipe-id.end","time":921},{"name":"activityTabFullyLoaded","time":1001.8999999761581}],"measures":[],"correlationId":"f41b06b77a08f0","effectiveType":"4g","downlink":9.2,"rtt":0,"serverDuration":109,"dbReadsTimeInMs":15,"dbConnsTimeInMs":24,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}
Added a test case for ARIA writes to the regression test suite.