Question

I would like to know how is it possible to test the lack time of master salve replication. For instance when a master has a record updated and a slave is replicating, how would it be possible to test the time interval within the replication process? Is there any software used or am i supposed to add in a column that is timestamp in my database?

I would not want to add in the timestamp column in the database because the system is already developed and i would not want to go through the entire codes to change the insert/update sql statements and amend the sql statement. My goal is to set up the replication and measure the time interval.

Advance thanks!

Was it helpful?

Solution

SHOW SLAVE STATUS on the slave will tell you how far behind it is.

The "correct" way to test the replication delay, however, is to continually poll the slave, and then fire a query on the master. The time it takes for the slave to receive the record is the replication delay.

In most setups, the lag is on the order of milliseconds.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top