We are seeing random deadlock errors when reading data from tables which are not being modified at the time of the select (they are updated only in nightly maintenance tasks). How is this possible? I thought deadlocks could only happen when there was some modification, but not when only reading, even if there is concurrent reading as is our case.
The exact error message is “WSREP detected deadlock/conflict and aborted the transaction. Try restarting the transaction”.
We are using a PXC with 2 nodes and:
wsrep_retry_autocommit=5 wsrep_drupal_282555_workaround=ON Percona Server version: 5.7.17-11-57-log - Percona XtraDB Cluster (GPL), Release rel11, Revision e2a7fdd, WSREP version 27.20, wsrep_27.20
How can we fix this?