Quantcast
Channel: StackExchange Replication Questions
Viewing all articles
Browse latest Browse all 17268

MySQL chain replication timing of writes on first slave

$
0
0

With a MySQL chain replication setup, e.g. M1->S1->S2, what exactly is the order of operations for writing to the first slave? Is the binary log from the master simply streamed directly through to the second slave? Or are database updates to the first slave committed before replicating those updates to the second slave?

The documentation for --log-slave-updates states This option causes the slave to write the updates performed by its SQL thread to its own binary log. It's not clear to me if this is done in parallel or only after data is written. I'm only interested in row-based replication, if that matters.

I ask because I have the unusual situation of a custom application acting as a second slave and operating on events that come through the binary log. It runs queries on the first slave. If the log events were to get to the application before writes on the first slave are committed, it will be operating on stale data.


Viewing all articles
Browse latest Browse all 17268

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>