Incahatus / mysql-master-ha

Automatically exported from code.google.com/p/mysql-master-ha
0 stars 0 forks source link

Duplicate entry 'localhost-mha' #60

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Dear,

I execute masterha_check_repl and I have error on my 2 slaves db.
I have 3 mysql server, 1 master and 2 slaves.
On each slave I have this :
[error][/usr/share/perl5/MHA/Server.pm, ln885] SQL Thread is stopped(error) on 
xx.xx.xx.xx(xx.xx.xx.xx:3306)! Errno:1062, Error:Error 'Duplicate entry 
'localhost-mha' for key 'PRIMARY'' on query. Default database: 'mysql'. Query: 
'update user set host='localhost' where user='mha''

But I haven't mysql user mha with host localhost. The user on mysql is :
GRANT ALL PRIVILEGES ON *.* TO 'mha'@'[server mha ip]' IDENTIFIED BY 
'[password]' WITH GRANT OPTION;

I try to add mysql user between each db and for localhost but the problem don't 
disappear.

Can you help me please.
Thanks

Marc

Original issue reported on code.google.com by teyssier...@gmail.com on 5 Apr 2013 at 9:25

GoogleCodeExporter commented 9 years ago
Ok, I found. My database had an error.
:-)

Original comment by teyssier...@gmail.com on 5 Apr 2013 at 12:28