首页  >  文章  >  数据库  >  ERROR 1201 (HY000):Could not initialize master info structur_MySQL

ERROR 1201 (HY000):Could not initialize master info structur_MySQL

WBOY
WBOY原创
2016-06-01 13:36:321063浏览

bitsCN.com

ERROR 1201 (HY000):Could not initialize master info structure的问题

 

今天在做MySQL主从复制时遇到个ERROR 1201 (HY000): Could not initialize master info structure .

出现这个问题的原因是之前曾做过主从复制!

解决方案是:运行命令 stop slave;

成功执行后继续运行 reset slave;

然后进行运行GRANT命令重新设置主从复制。

具体过程如下:

Command代码  

mysql> change master to master_host='127.0.0.1', master_user='user', master_pass  

word='user', master_log_file='mysql-bin-000202', master_log_pos=553;  

ERROR 1201 (HY000): Could not initialize master info structure; more error messa  

ges can be found in the MySQL error log  

mysql> stop slave;  

Query OK, 0 rows affected, 1 warning (0.00 sec)  

  

mysql> reset slave;  

Query OK, 0 rows affected (0.00 sec)  

  

mysql> change master to master_host='127.0.0.1', master_user='user', master_pass  

word='user', master_log_file='mysql-bin-000202', master_log_pos=553;  

Query OK, 0 rows affected (0.11 sec)  

 

bitsCN.com
声明:
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn