MySQL Forums
Forum List  »  Replication

Re: Is ROW replication format optimized to skip duplicated rows in the log?
Posted by: Rick James
Date: November 01, 2012 10:25PM

The Master does not know how "caught up" the Slave(s) is, so it sends the information regardless. Each Slave has no "look ahead", so it will execute all 20. This should be the case for both SBR and RBR.

(Caveat: I have no proof of what I say, it merely comes from an understanding of how things work.)

The amount of data sent via RBR vs SBR is about the same for a single-row UPDATE, so I see little difference in network traffic or other performance issues.

I do not know what happens if you update a row to the same value. It is conceivable that the UPDATE is not sent to the slave.

If replication is 5 minutes behind, you have some seriously slow queries being replicated. Find some of them; let's discuss optimizing them. (Even 5 seconds is too "long" in my book!)

If, on the other hand, you do something like
UPDATE tbl SET foo=1 WHERE x=2;
without an index on x, then it will scan the entire table. This is slow on the Master. On the Slave it also be slow if SBR but will be fast for RBR since the replication stream will include the PRIMARY KEY. This example would not lead to replication delay since the Master is at least as slow as the slave.
(Have an index starting with x !)

If the Slave is "less powerful" than the Master, that could contribute to replication delays.

Options: ReplyQuote


Subject
Views
Written By
Posted
Re: Is ROW replication format optimized to skip duplicated rows in the log?
1131
November 01, 2012 10:25PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.