[MDEV-27130] Node of Galera Cluster with 5 Members freezes after directing traffic of it Created: 2021-11-27 Updated: 2023-05-15 Resolved: 2023-05-15 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Galera, Platform FreeBSD, Storage Engine - InnoDB |
| Affects Version/s: | 10.5.13 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Critical |
| Reporter: | Rumen Palov | Assignee: | Seppo Jaakola |
| Resolution: | Cannot Reproduce | Votes: | 5 |
| Labels: | None | ||
| Environment: |
MariaDB 10.5.13 , galera provider 26.4.10 ,FreeBSD 12 and 13 . ZFS storage, 1500G RAM , 64 or 96 Cores |
||
| Attachments: |
|
| Description |
|
Hello all, We updated our MariaDB Galera Cluster to 10.5.13 last week. Since then we are facing following issue each time when try to switch the "master" node. When we switch the traffic from one node to other at the time of medium loaded service - 15-20000 q/s, the new node freezes in brutal way. The wsrep status stays as it is normal member of the cluster - Synced with 5 IPs listed, but other members exclude it from the quorum. The log is filled in infinitive loop with following messages: InnoDB: WSREP: BF lock wait long for trx:11255701331 query: INSERT INTO In the log are repeated the same 7-10 unique INSERTS. The whole cluster freezes until we shutdown the mysqld on "bad" node with regular service shutdown - /usr/local/etc/rc.d/mysql-server onestop. When we try to stop the Node with regular shutdown procedure the node is excluded from the cluster and service operations continue as normal. But the mysqld is going to print The specific thing here is the query ( INSERT ) and target table are always the same. We have massive INSERT load to this table and one daemon which process the data on background. If we stop the daemon before node switching there are no issues. Cheers |
| Comments |
| Comment by MikaH [ 2022-01-19 ] |
|
From which version the upgrade was done? Can you please share the configuration file(s)? |
| Comment by Rumen Palov [ 2022-01-24 ] |
|
Hello , Versions history is as follows: MySQL 5.7 Configuration files are quit different now. I will try to restore the version from Nov 2021. Cheers |
| Comment by Jan Lindström (Inactive) [ 2022-04-20 ] |
|
valerii I would need show processlist and show engine innodb status outputs and full error log on all nodes. |
| Comment by Jan Lindström (Inactive) [ 2022-04-21 ] |
|
ramesh Can you test this using galapq (yes no FreeBSD) so that we know is this FreeBSD only problem. |
| Comment by Ramesh Sivaraman [ 2022-04-26 ] |
|
jplindst julien.fritsch Could not reproduce this issue on galapq (ubuntu) server. |
| Comment by Jan Lindström (Inactive) [ 2022-04-26 ] |
|
We would need:
We could not reproduce the issue. This could be FreeBSD only issue. |
| Comment by Jan Lindström (Inactive) [ 2022-05-30 ] |
|
valerii Full backtrace from 10.6ES is not very useful to analyze problem on 10.5CS. Maybe better to escalate to Codership. |
| Comment by Mathieu CAUSERO [ 2022-07-27 ] |
|
Hello there, We do have the same issue happening on a 3-nodes MariaDB Galera Cluster running 10.4.24 on Debian 10. The SQL workload is fully load balanced between the 3 nodes, the average metrics during workday are (on each node) :
The issue mostly happens with 2 or 3 INSERT transactions on the same table (with different values). The table is about 43M rows with 31GB of datas and 20GB of index. When it happens, a graceful stop of "bad" node does unblock the whole cluster but it always needs some SIGKILL to be able to restart the service. Usually the restarted node does sync with IST, sometimes it needs a SST (whereas the configured 1 GB cache should cover about 3 hours of downtime...). We keep track of each incident with full processlist on JSON format + mysqld log (with "WSREP: BF lock wait long for" messages). How can we privately send you these informations that might be useful to troubleshoot the issue ? |
| Comment by Valerii Kravchuk [ 2022-08-04 ] |
|
Hi Mathieu CAUSERO, Backtrace of all threads taken with gdb when node hangs would be a good start. I think it can be shared in public as it does not contain any really sensitive information (please, review and check if in doubts before attaching). |
| Comment by Jan Lindström (Inactive) [ 2022-08-04 ] |
|
mathieucausero I have few questions. Do you have primary key on all tables affected? Do you have foreign keys between tables affected? Do you use auto increment as primary key column and if you do, do you set different offset for every node? |
| Comment by Mathieu CAUSERO [ 2022-08-04 ] |
|
@Jan Lindström to answer your few questions :
From what I see on our customer's database, every impacted table (= every table that have had requests involved in cluster deadlock) is made like this. Would that composed PK be an issue ? To add a bit more context, the most impacted table is made of 68M rows with 36GB of datas. It's taken dozens of INSERT per second from 3 galera nodes (all are used as writers). Servers are all baremetal servers with 128GB of RAM (InnoDB buffer pool is bigger than the datas+index size), NVMe storage, 2 Gbit/s private network with MTU 9000. |
| Comment by Jan Lindström [ 2023-05-15 ] |
|
There has been significant fixes on Galera conflict resolution and multi-master execution. I suggest trying more recent version of MariaDB and Galera library. |