mha4mysql-manager
mha4mysql-manager copied to clipboard
fixed MHA online switch master,when orig_master and new_master is same.
when you switch master online,masterha_master_switch --master_state=alive --conf=/etc/masterha/app1.conf --new_master_host=xxxx --new_master_port=xxx, you new_master_host and new_master_port is same as you orig_master_host orig_master_port,MHA will execute function reject_update,it cause master failover vip change and set read_only on it until master_pos_wait exit.
Trying to write the bug description in proper english as far as i can understand:
when you switch the master online:
masterha_master_switch --master_state=alive --conf=/etc/masterha/app1.conf --new_master_host=xxxx --new_master_port=xxx
with your new_master_host
and new_master_port
being the same as you orig_master_host
and orig_master_port
MHA will execute function reject_update
, causing master failover vip change and set it to read_only until master_pos_wait
exits.