[MDEV-24756] 100% cpu load when idle on arm v7 Created: 2021-02-01 Updated: 2021-09-09 Resolved: 2021-06-26 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Server |
| Affects Version/s: | 10.5.8 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Major |
| Reporter: | Andre R | Assignee: | Unassigned |
| Resolution: | Cannot Reproduce | Votes: | 0 |
| Labels: | regression | ||
| Environment: |
Fresh alpine linux 3.13 container running on an arm v7 debian 10.7 host |
||
| Attachments: |
|
| Description |
|
Issue has also been filed in alpine packages The following issue appeared with mariadb 10.5.8 (there is no issue with alpine 3.12 and mariadb 10.4.x):
I see only one difference in start logs (but that may be irrelevant):
Any idea why this happens and if there is an option in mysqld to circumvent the issue? Steps to reproduce:
|
| Comments |
| Comment by Daniel Black [ 2021-02-02 ] | |||||||||||||||||||||||||||||||||||||||||||
|
On arm v7 can you obtain two backtraces (with a few seconds between them): https://mariadb.com/kb/en/how-to-produce-a-full-stack-trace-for-mysqld/#getting-backtraces-from-a-running-mysqld-process-with-gdb-on-linux including ' Also can you perform a `perf record -g -p $(pidof mysqld) – sleep 2` / `perf report -g --no-children --stdtio` to show where the CPU time is spent. Can you execute SQL like 'SHOW PROCESSLIST', 'SHOW ENGINE STATUS INNODB', 'SHOW GLOBAL STATUS'? Can you attach these outputs to this JIRA issue please? The lack of v7 optimized CPU isn't likely to cause 100% CPU, however the backtraces will show this. | |||||||||||||||||||||||||||||||||||||||||||
| Comment by Andre R [ 2021-02-03 ] | |||||||||||||||||||||||||||||||||||||||||||
1. BacktracesI'm afraid the backtraces won't be very useful :
I see no "debug" package in my linux distribution. So I should compile mariadb myself to have symbols? 2. perf reportI guess this one is not very useful neither:
3. SQL commandsThis one is larger so I attach the output. mariadb_sql_commands.txt | |||||||||||||||||||||||||||||||||||||||||||
| Comment by Andre R [ 2021-02-03 ] | |||||||||||||||||||||||||||||||||||||||||||
|
Additional info requested by alpine team in the alpine bug | |||||||||||||||||||||||||||||||||||||||||||
| Comment by Andre R [ 2021-02-03 ] | |||||||||||||||||||||||||||||||||||||||||||
perf report (continued)It took me some more effort to produce the perf.data file. I hope it contains useful information. perf.data | |||||||||||||||||||||||||||||||||||||||||||
| Comment by Daniel Black [ 2021-02-03 ] | |||||||||||||||||||||||||||||||||||||||||||
|
perf.data is rather raw, it needs the ELF binary to resolve. Can you try `perf report -g --no-children -i ~/perf.data` and/or `objdump -d /usr/bin/mysqld` should give address that we can map to the perf data. Thanks for trying strace, its looking very much like an endless loop. The gdb of the running process will still be useful if you have it compiled with debug symbols (cflag=-g). | |||||||||||||||||||||||||||||||||||||||||||
| Comment by Josh Richards [ 2021-03-02 ] | |||||||||||||||||||||||||||||||||||||||||||
|
Not the OP but since it looks like there is some further data being waited on I thought I'd tried to provide it as I ran across this issue last night as well. perf.data + perf.report output attached from my setup perf.report | |||||||||||||||||||||||||||||||||||||||||||
| Comment by Andre R [ 2021-03-02 ] | |||||||||||||||||||||||||||||||||||||||||||
|
(cross posted in alpine issue) mariadb (and co) from 10.5.8 to 10.5.9 I'd rather say (but I can't be sure) that musl was the culprit of the bug, as mariadb 10.5.8 used to run fine in a debian/buster container instead of alpine. | |||||||||||||||||||||||||||||||||||||||||||
| Comment by Daniel Black [ 2021-06-26 ] | |||||||||||||||||||||||||||||||||||||||||||
|
Thanks for getting back to us andre_r. It appears from your upstream bug that both musl and mariadb have been updated on alpine 3.13/armv7. At the moments its a bit hard to determine the cause. We'd need musl MDBF-244, an armv7/armhf/Arm Cortex support in CI, and maybe even a alpine based testing (MDEV-18462) to find this kind of issue prerelease.
| |||||||||||||||||||||||||||||||||||||||||||
| Comment by Marko Mäkelä [ 2021-09-09 ] | |||||||||||||||||||||||||||||||||||||||||||
|
andre_r, in MariaDB 10.5.9 there was also a fix of It would be interesting to try MariaDB 10.5.8 with the newer musl libc and 10.5.9 with the older libc, to narrow down the culprit. |