We use Mixed replication in RDS mysql 5.6 and we are noticing replication lag every few minutes or so, the lag appears momentarily and then disappears. On slaves when we do show processlist we saw update and long insert queries (sometimes).

Previously in MYSQL 5.5 we used statement based replication and never encountered insert and update queries appearing on slaves, there are no other systems writing to slaves so this is ruled out.

Can any one suggests what could be the problem of this occasional lag.

  • Is your slave applying transactions in single thread? If yes then master can outperform it, because it can apply multiple inserts and updates in parallel. – jkavalik Jul 23 '15 at 20:46
  • how to check and fix this single thread issue ? – roger moore Jul 24 '15 at 7:39
  • Read dev.mysql.com/doc/refman/5.6/en/replication-options-slave.html but it seems to only apply when you replicate multiple databases (afaik MariaDB can do it on one database too). Why are you concerned about the lag? If binlog is properly transfered then it will be applied. Master-slave is asynchronous by default. There are some possibilities of Synchronous replication (galera cluster and maybe others) but it comes with a price. – jkavalik Jul 24 '15 at 8:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.