重启了一下从库,忘记先stop slave ,直接mysqladmin shutdown关闭实例,结果起不来了

mysql> start slave;
ERROR 1872 (HY000): Slave failed to initialize relay log info structure from the repository

这个错误就是relay log有问题,但我看自己的配置中有配置relay_log参数,但为什么从库启动会在此处出问题呢

重新开启同步,先记下当前从库同步的位置

mysql> show slave status\G;
*************************** . row ***************************
Slave_IO_State:
Master_Host: 10.*.*.*
Master_User: db_slave
Master_Port:
Connect_Retry:
Master_Log_File: mysql-bin.
Read_Master_Log_Pos:

reset master;
reset slave all;

mysql> CHANGE MASTER TO
-> MASTER_HOST='10.***',
-> MASTER_USER='db_slave',
-> MASTER_PASSWORD='***********',
-> MASTER_PORT=3301,
-> MASTER_LOG_FILE='mysql-bin.013463',
-> MASTER_LOG_POS=247058609,
-> MASTER_CONNECT_RETRY=10;
ERROR 29 (HY000): File '/data/mysql_3301/var/mysql-relay-bin.000001' not found (Errcode: 2 - No such file or directory)

结果还是报错,还是关于relay log的,然后

修改配置文件,新建一个目录,重新为relay log指定一个目录,不再使用原来的目录

relay_log                      = /data/mysql_3301/log/mysql-relay-bin

再次CHANGE MASTER TO……,start slave,这次从库成功启动了

my26_Slave failed to initialize relay log info structure from the repository的更多相关文章

  1. ERROR 1872 (HY000): Slave failed to initialize relay log info structure from the repository

    salve复制线程停止,尝试start slave 时报ERROR 1872错误mysql> system perror 1872 MySQL error code 1872 (ER_SLAVE ...

  2. Slave failed to initialize relay log info structure from the repository

    现象 查看slave 服务状态 show slave status\G; 错误 Last_Errno: 1872 Last_Error: Slave failed to initialize rela ...

  3. 【故障处理】ERROR 1872 (HY000): Slave failed to initialize relay log info structure from the repository

    今天在使用冷备份文件重做从库时遇到一个报错,值得研究一下. 版本:MySQL5.6.27 一.报错现象 dba:(none)> start slave; ERROR (HY000): Slave ...

  4. MySQL复制报错(Slave failed to initialize relay log info structure from the repository)

    机器重启以后,主从出现了问题,具体报错信息: Slave failed to initialize relay log info structure from the repository 解决方案: ...

  5. my32_ error 1872 Slave failed to initialize relay log info structure from the repository

    重启了实例后,slave进程无法开启 Last_SQL_Errno: Last_SQL_Error: Slave failed to initialize relay log info structu ...

  6. mysql报错1872: Slave failed to initialize relay log info structure from the repository

    ERROR 1872 (HY000): Slave failed to initialize relay log info structure from the repository 在一台主机上增加 ...

  7. mysql 主从关系ERROR 1872 (HY000): Slave failed to initialize relay log info structure from the repository

    连接 amoeba-mysql出现Could not create a validated object, cause: ValidateObject failed mysql> start s ...

  8. mysql5.7启动slave报错 ERROR 1872 (HY000): Slave failed to initialize relay log info structure from the repository

    原因:检查my.cnf,原来没指定relay_log,mysql默认产生的relay_log名被该server上的另一个mysql slave占用了. 解决方法:1.在my.cnf中添加 relay_ ...

  9. MySQL主从报错解决:Failed to initialize the master info structure

    大清早收到一个MySQL的自定义语言告警 :replication interrupt,看来是主从同步报错了. 登陆MySQL,执行 show slave status \G 发现salve已经停止了 ...

随机推荐

  1. js转化与排序

    1.对象转化为数组 object.keys() var obj={a:3,b:7,c:8,d:false} alert(Object.keys(obj)) 注意此函数会把对象的key转化为数组 spl ...

  2. Python 网络爬虫 001 (科普) 网络爬虫简介

    Python 网络爬虫 001 (科普) 网络爬虫简介 1. 网络爬虫是干什么的 我举几个生活中的例子: 例子一: 我平时会将 学到的知识 和 积累的经验 写成博客发送到CSDN博客网站上,那么对于我 ...

  3. Luogu 2939 [USACO09FEB]改造路Revamping Trails && Luogu 4568 [JLOI2011]飞行路线

    双倍经验 写这两题之前被大佬剧透了呜呜呜. 分层图+最短路. 因为有$k$次机会能够把路径的费用变为$0$,我们可以建$k + 1$层图,对于每一层图我们把原来的边权和双向边连到上面去,而对于层与层之 ...

  4. 数据结构与算法(Java版)_堆

    完全二叉树叫做堆. 完全二叉树就是最后一个节点之前不允许有不满的节点,就是不允许有空洞. 可以使用数组来做完全二叉树(堆). 堆分为大顶堆和小顶堆.大顶堆就是根节点上的数字是最大的,小顶堆就是根节点上 ...

  5. STL-- vector中resize()和reserve()区别

    最近写了一个小型的STL--TinySTL.发现有一些基础的东西需要记录下来,所以我打算多写一些东西,方便以后查看. 先看看<C++ Primer>中对resize()函数两种用法的介绍: ...

  6. java求几个数字的和输出详细步骤

    设计思想:要求几个数字的和,就要把输入的字符串转换成浮点型,然后求和再输出. 程序流程图: 程序源代码: //此程序用于从命令行接收多个数字,就和并输出. //作者:赵东睿 //2015.9.26 p ...

  7. [译]Javascript中的错误信息处理(Error handling)

    本文翻译youtube上的up主kudvenkat的javascript tutorial播放单 源地址在此: https://www.youtube.com/watch?v=PMsVM7rjupU& ...

  8. arcgis调用国家天地图wfs服务

    1.国家天地图wfs地址 getcapabilities http://www.tianditu.com/wfssearch.shtml?request=getcapabilities&ser ...

  9. jquery easyui datagrid 多选只能获取一条数据

    DataGrid属性: singleSelect ------如果为true,则只允许选择一行: idField ------- 指明哪一个字段是标识字段: 方法: 一:getSelections-- ...

  10. SQL CTE 递归 查询省,市,区

    IF OBJECT_ID('tb') IS NOT NULL DROP TABLE tb ) , pid ) , name )) ' , null , '广东省') ' , '广州市') ' , '深 ...