How easy is it to identify and debug Percona XtraDB Cluster replication problem ?
If you are using PXC, you may have already seen in your datadirectory several log files starting with GRA_
Those files correspond to a replication failure. That means the slave thread was not able to apply one transaction. For each of those file, a corresponding warning or error message is present in the mysql error log file.
Those error can also be false positive like a bad DDL statement (DROP a table that doesn’t exists for example) and therefore nothing to worry about. However it’s always recommended to understand what’s is happening.
As the GRA files contain binlog events in ROW format representing the failed transaction this post explains how to proceed.
The first step to be able to analyze your GRA files is to add a
binlog header to the file.
You can download one here : …