mha4mysql-manager icon indicating copy to clipboard operation
mha4mysql-manager copied to clipboard

Patch for MHA when using {master,relay_log}_info_repository = TABLE

Open sjmudd opened this issue 10 years ago • 2 comments

I was trying MHA and noticed on the servers I use that it does not work properly on MySQL 5.6 with the following settings:

master_info_repository = TABLE relay_log_info_repository = TABLE

I notice that there is code to check for the value being TABLE and not FILE but it does not work, at least not in the 0.56 rpms that I have been using.

There are 2 patches which can be found at: http://ftp.wl0.org/mha/

Please consider incorporating these patches into MHA. Note: 1 patch is for the manager and another one is for the node. I'm only making 1 issue but can make a separate one for https://github.com/yoshinorim/mha4mysql-node if that's better.

sjmudd avatar Sep 22 '14 08:09 sjmudd

Has this bug been fixed in a different way? I was not able to reproduce the problem @sjmudd had.

grypyrg avatar Dec 09 '15 13:12 grypyrg

I have been to reproduce. You just need the master to have an empty mysql.slave_relay_log_info and the /usr/bin/masterha_check_repl script breaks in Server.pm at line 241:

Wed Nov 16 09:17:28 2016 - [error][/usr/share/perl5/MHA/Server.pm, ln241] Getting relay log directory or current relay logfile from replication table failed on 10.10.10.20(10.10.10.20:3306)!

root@egov-monitor-00:~# mysql -h 10.10.10.20 -u mha_user -p -e 'show slave status\Gshow master status;select * from mysql.slave_relay_log_info;' Enter password: +------------------------+-----------+--------------+------------------+-------------------+ | File | Position | Binlog_Do_DB | Binlog_Ignore_DB | Executed_Gtid_Set | +------------------------+-----------+--------------+------------------+-------------------+ | mysqld-bin.002816 | 869689395 | | | | +------------------------+-----------+--------------+------------------+-------------------+

y-trudeau avatar Nov 16 '16 15:11 y-trudeau