[MDEV-20414] "a long semaphore wait" After Upgrading to 10.1.41 Created: 2019-08-23 Updated: 2023-02-17 |
|
| Status: | Open |
| Project: | MariaDB Server |
| Component/s: | Storage Engine - InnoDB |
| Affects Version/s: | 10.1.41 |
| Fix Version/s: | 10.1 |
| Type: | Bug | Priority: | Major |
| Reporter: | James Coleman | Assignee: | Marko Mäkelä |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Environment: |
CentOS Linux release 7.6.1810 |
||
| Attachments: |
|
||||||||||||
| Issue Links: |
|
||||||||||||
| Description |
|
Ever since we upgraded to 10.1.41, we have been having non-stop issues in several of our large servers where the logs start filling up with semaphore errors and working with any InnoDB table seems to lock up. Doing research, I found people talking about disabling the `innodb_adaptive_hash_index` by setting it to 0 to fix the issue, and I have tried this without success. With it disabled, the issue still crops back up. Doing some more research, I found issue #16467 (https://jira.mariadb.org/browse/MDEV-16467) which was in the update log for MariaDB 10.1.41, so I am wondering if that is related to our issues. Any help will be awesome. I have attached the log output we see. |
| Comments |
| Comment by James Coleman [ 2019-10-23 ] | ||||||||||
|
We are still examining this issue to this day. As an update, it seems to only popup when MariaDB is under heavy load. Rather it be lots of cron jobs running heavy queries at the same time, or lots of traffic on a site. | ||||||||||
| Comment by Marko Mäkelä [ 2019-10-23 ] | ||||||||||
|
james.coleman-ah, could you attach gdb to the mysqld process while it is hung, and provide a stack of all threads, and also information about the dictionary latches?
We want to be able to detect the chain of blocked mutexes or rw-latches and threads. | ||||||||||
| Comment by James Coleman [ 2019-11-08 ] | ||||||||||
|
I was finally able to get a dump for you attached. | ||||||||||
| Comment by Marko Mäkelä [ 2019-11-11 ] | ||||||||||
|
james.coleman-ah, thank you. Unfortunately, the 2 print commands were rejected, because no debugging symbols were available. Often they are part of a separate package, such as MariaDB-server-debuginfo.
I think that valerii has mentioned that setting STATS_AUTO_RECALC=1 STATS_PERSISTENT=1 for InnoDB tables can cause problems. I failed to find an open bug report for that one, though. Given that you seem to have lots of concurrent operations that involve FOREIGN KEY constraints, Without having more information available, it is very difficult to diagnose this. Next time the hang occurs, could you please generate a core dump? Then, with the appropriate debugging symbols installed, we should be able to extract more data from it. | ||||||||||
| Comment by Marko Mäkelä [ 2023-02-17 ] | ||||||||||
|
Some statistics related hangs were fixed in |