[MDEV-8568] Log noise: "MDL conflict db=%s table=%s ticket=%d solved by abort" Created: 2015-08-03  Updated: 2015-08-06  Resolved: 2015-08-06

Status: Closed
Project: MariaDB Server
Component/s: Galera, Locking
Affects Version/s: 10.0.16
Fix Version/s: N/A

Type: Bug Priority: Minor
Reporter: Karl E. Jørgensen Assignee: Nirbhay Choubey (Inactive)
Resolution: Not a Bug Votes: 0
Labels: None


 Description   

We are getting very frequent log noise in the style of:

Jun 30 12:48:08 node03 mysqld: 150630 12:48:08 [Note] WSREP: MDL conflict db=xxxschema table=xxxTableName ticket=7 solved by abort

After investigation I concluded that these log messages are misleading (nothing is "aborted" - just blocked for a little bit) - in addition to very noisy. They only occur with MariaDB Galera - stock MariaDB does not emit such noise.

I can reproce it with 2 sessions against the same MariaDB Galera cluster node:

Session 1 Session 2
set autocommit=0;  
LOCK TABLES SomeTable WRITE;  
  SELECT * FROM SomeTable - this will hang and the message appears in the log.
UNLOCK TABLES;  
  this session is unleashed again

Looking at the code sql/mdl.cc, this is a message which is emitted when the 2nd session is forced to wait.

Thus it is an indication of lock contention, and not an error. Since the thread is forced to wait, and no errors occur, database consistency is preserved.

In our case the message is frequent as our app does LOCK TABLE.

Can the logging level of this message be reduced to DEBUG ? The non-galera MySQL build is quiet under the same circumstances, and the log message is not really wsrep specific.

At the very least, can we avoid the usage of the word "abort" - this indicates a problem where there is none...



 Comments   
Comment by Nirbhay Choubey (Inactive) [ 2015-08-06 ]

Hi jorginator : These messages can be skipped by turning off wsrep_log_conflicts.

https://mariadb.com/kb/en/mariadb/galera-cluster-system-variables/#wsrep_log_conflicts

Generated at Thu Feb 08 07:28:07 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.