Description:
There are some ha solutions,like replication,semi-sync,storage,mysql cluser.they provide more data consistency.
But I need a feature that the ha_master switch can happen even when the slave has many Seconds_Behind_Master if the master is down ,because I want the application access mysql as soon as possible.
When slave replication Seconds_Behind_Master is happen,if the master is down,the two slave already dump the binlog to local disk into relay log,but if I change master to a slave which is elected being new master ,the server will purge the local relay log,and replicate the same binlog events again from the new master(another slave ) after the binlog events have been executed by the new master.
How to repeat:
every time the master is down when the slaves have many seconds behind master.
Suggested fix:
MySQL should provide two features:
change master command have two more parameters:
A、skip_relay_log_purge
0:purge local relay log
1:do not purge local relay log
B、Replicate_Ignore_Server_ID
do not replicate the events from old master.
Description: There are some ha solutions,like replication,semi-sync,storage,mysql cluser.they provide more data consistency. But I need a feature that the ha_master switch can happen even when the slave has many Seconds_Behind_Master if the master is down ,because I want the application access mysql as soon as possible. When slave replication Seconds_Behind_Master is happen,if the master is down,the two slave already dump the binlog to local disk into relay log,but if I change master to a slave which is elected being new master ,the server will purge the local relay log,and replicate the same binlog events again from the new master(another slave ) after the binlog events have been executed by the new master. How to repeat: every time the master is down when the slaves have many seconds behind master. Suggested fix: MySQL should provide two features: change master command have two more parameters: A、skip_relay_log_purge 0:purge local relay log 1:do not purge local relay log B、Replicate_Ignore_Server_ID do not replicate the events from old master.