mysql安装失败原因和解决方法(MySQL MGR搭建过程中常遇见的问题及解决办法)
mysql安装失败原因和解决方法
MySQL MGR搭建过程中常遇见的问题及解决办法mgr搭建过程中遇到的一些故障
实际中我一共部署了三套mgr环境,分别是单机多实例的mgr环境,多机同网段的mgr环境,多机不同网段的mgr环境,部署的过程大同小异,但是还是有一些有出入的地方,这里把部署过程遇到的故障列举出来,供大家参考,如果能有幸解决您在部署时候的问题,那是极好的。
01 常见故障1
|
[error] plugin group_replication reported: 'this member has more executed transactions than those present in the group. local transactions: bb874065-c485-11e8-8b52-000c2934472e:1 > group transactions: 3db33b36-0e51-409f-a61d-c99756e90155:1-11' [error] plugin group_replication reported: 'the member contains transactions not present in the group. the member will now exit the group.' [note] plugin group_replication reported: ‘ to force this member into the group you can use the group_replication_allow_local_disjoint_gtids_join option ' |
解决方案:
根据提示打开set global group_replication_allow_local_disjoint_gtids_join=on;
02 常见故障2
|
[error] plugin group_replication reported: 'this member has more executed transactions than those present in the group. local transactions: bb874065-c485-11e8-8b52-000c2934472e:1 > group transactions: 3db33b36-0e51-409f-a61d-c99756e90155:1-15' [warning] plugin group_replication reported: 'the member contains transactions not present in the group. it is only allowed to join due to group_replication_allow_local_disjoint_gtids_join option' [note] plugin group_replication reported: 'this server is working as secondary member with primary member address localhost.localdomaion:3306.' |
解决方案:
该故障和故障1的不同之处在于该问题出现时,参数group_replication_allow_local_disjoint_gtids_join已经设置成为on了。解决该问题的方法是执行reset master就行,然后重新在主节点和从节点开启通道,即
change master to master_user='rpl_user', master_password='rpl_pass' for channel 'group_replication_recovery';
03 常见故障3
本机测试时,遇到下面的问题
|
[warning] storing mysql user name or password information in the master info repository is not secure and is therefore not recommended. please consider using the user and password connection options for start slave; see the 'start slave syntax' in the mysql manual for more information. [error] slave i/o for channel 'group_replication_recovery' : error connecting to master 'rpl_user@localhost.localdomaion:' - retry- time : 60 retries: 1, error_code: 2005 [error] plugin group_replication reported: 'there was an error when connecting to the donor server. please check that group_replication_recovery channel credentials and all member_host column values of performance_schema.replication_group_members table are correct and dns resolvable.' [error] plugin group_replication reported: 'for details please check performance_schema.replication_connection_status table and error log messages of slave i/o for channel group_replication_recovery.' [note] plugin group_replication reported: 'retrying group recovery connection with another donor. attempt /' |
解决方案:
这个问题是由于测试环境上三台主机的hostname设置成为了同一个名称,改了hostname之后,这个问题就解决了。
04 常见故障4
|
#在线上正式环境操作时,出现下面的错误, mysql --root@localhost:(none) ::>>start group_replication; error (hy000): the server is not configured properly to be an active member of the group . please see more details on error log. #查看log文件,发现只有一个warning: 2019-02-20t07::30.233937z [warning] plugin group_replication reported: ' group replication requires slave-preserve- commit - order to be set to on when using more than 1 applier threads. |
解决方案:
|
mysql --root@localhost:(none) ::>>show variables like "%preserve%"; + --------------------------------+---------+ | variable_name | value | + --------------------------------+---------+ | slave_preserve_commit_order | off | + --------------------------------+---------+ row in set (0.01 sec) mysql --root@localhost:(none) ::>>set global slave_preserve_commit_order=; query ok, rows affected (0.00 sec) |
05 常见问题5
|
2019-02-20t08::31.088437z [warning] plugin group_replication reported: '[gcs] connection attempt from ip address 192.168.9.208 refused. address is not in the ip whitelist.' 2019-02-20t08::32.088676z [warning] plugin group_replication reported: '[gcs] connection attempt from ip address 192.168.9.208 refused. address is not in the ip whitelist.' |
解决方法:
在my.cnf中配置group_replication_ip_whitelist参数即可解决
06 常见问题6
|
2019-02-20t08::44.087492z [warning] plugin group_replication reported: 'read failed' 2019-02-20t08::44.096171z [error] plugin group_replication reported: '[gcs] the member was unable to join the group. local port: 24801' 2019-02-20t08::14.065775z [error] plugin group_replication reported: 'timeout on wait for view after joining group |
解决方案:
将my.cnf中的参数group_replication_group_seeds设置为只包含除自身外其他group成员的ip地址以及内部通信端口,如果写成group所有成员的ip地址,则会出现这个错误,这和相同网段的mgr部署方式有些差异。
07 常见问题7
|
[error] plugin group_replication reported: ‘[gcs] error on opening a connection to oceanbase07: on local port: '.' [error] plugin group_replication reported: ‘[gcs] error on opening a connection to oceanbase08: on local port: '.' [error] plugin group_replication reported: ‘[gcs] error on opening a connection to oceanbase07: on local port: '.' |
解决方案:
未开通防火墙上的固定端口,开通防火墙之后即可解决
08 常见问题8
|
[warning] storing mysql user name or password information in the master info repository is not secure and is therefore not recommended. please consider using the user and password connection options for start slave; see the 'start slave syntax' in the mysql manual for more information. [error] slave i/o for channel 'group_replication_recovery' : master command com_register_slave failed: access denied for user 'rpl_user' @ '%' (using password : yes) (errno: 1045), error_code: 1597 [error] slave i/o thread couldn 't register on master [note] slave i/o thread exiting for channel ' group_replication_recovery ', read up to log ' first ', position |
解决方案:
漏掉了某个节点的用户,为了保险起见,在group节点上执行
create user rpl_user@'%';
grant replication slave on *.* to rpl_user@'%' identified by 'rpl_pass';
09 常见问题9
|
[error] failed to open the relay log './localhost-relay-bin.000011' (relay_log_pos ). [error] could not find target log file mentioned in relay log info in the index file './work_nat_1-relay-bin. index' during relay log initialization. [error] slave: failed to initialize the master info structure for channel '' ; its record may still be present in 'mysql.slave_master_info' table , consider deleting it. [error] failed to open the relay log './localhost-relay-bin-group_replication_recovery.000001' (relay_log_pos ). [error] could not find target log file mentioned in relay log info in the index file './work_nat_1-relay-bin-group_replication_recovery.index' during relay log initialization. [error] slave: failed to initialize the master info structure for channel 'group_replication_recovery' ; its record may still be present in 'mysql.slave_master_info' table , consider deleting it. [error] failed to create or recover replication info repositories. [error] slave sql for channel '' : slave failed to initialize relay log info structure from the repository, error_code: [error] /usr/ local /mysql/bin/mysqld: slave failed to initialize relay log info structure from the repository [error] failed to start slave threads for channel '' |
解决方案:
这个错误是由于slave节点由于某种原因导致找不到relay-log的位置了,需要重新reset slave
以上就是mysql mgr搭建过程中常遇见的问题及解决办法的详细内容,更多关于mysql mgr搭建的资料请关注开心学习网其它相关文章!
原文链接:https://cloud.tencent.com/developer/article/1533657
- mysql5.5.36版本介绍(WDCP控制面板升级mysql为5.7.11的方法)
- 用mysql编写test数据库(MySQL制作具有千万条测试数据的测试库的方法)
- mysql删除表内所有数据(mysql 大表批量删除大量数据的实现方法)
- mysql修改初始密码教程(使用MySQL命令行修改密码)
- mysql 命令与sqlserver的区别大么(MySQL系列之执行SQL 语句时发生了什么?)
- mysql创建表存在哪里(MySQL的表空间是什么)
- mac的mysql连接问题如何解决(MAC 中mysql密码忘记解决办法)
- 查询按照部门分组的mysql语句(Mysql根据某层部门ID查询所有下级多层子部门的示例)
- 在mysql语法中用来修改数据的命令(explain命令为什么可能会修改MySQL数据)
- mysqlworkbench怎么设置连接(详解MySQL Workbench使用教程)
- mysql三种查询方式(MySQL查询学习之基础查询操作)
- mysql设置updatetime自动更新(mysql 实现添加时间自动添加更新时间自动更新操作)
- 如何在cmd里开启mysql(Windows下通过cmd进入DOS窗口访问MySQL数据库)
- mysql密码过期怎么改(年底了,你的mysql密码安全吗)
- mysqlselect语句汇总(MySQL Select语句是如何执行的)
- mysql8.0.16安装步骤图解(mysql 8.0.22 安装配置图文教程)
- 原创图画书,以儿童视角讲述中国故事(以儿童视角讲述中国故事)
- 八月再见 愿你岁月不扰,余生静好(八月再见愿你岁月不扰)
- 赏读 八月再见,九月你好(赏读八月再见九月你好)
- 散文 八月再见,九月,我在风中等你(散文八月再见九月)
- 8月再见 9月你好(8月再见)
- 魔兽世界 设计师爆料,原始版本并无PVP,跨阵营属于返璞归真(魔兽世界设计师爆料)
热门推荐
- php多维数组怎么转换json(php实现的数组转xml案例分析)
- CSS3动画属性animation
- sql语句无效数字(SQL中写入包含有英文单引号“ '' ”失败问题深入详解)
- vuex数据持续化(Vuex数据持久化实现的思路与代码)
- php有几种模式(php 策略模式原理与应用深入理解)
- sqlserver 高级查询(SQL Server2019数据库之简单子查询的具有方法)
- python怎么输出一个矩阵(python实现转圈打印矩阵)
- php验证码图解(php/JS实现的生成随机密码验证码功能示例)
- 查看mysql所有权限(MySQL 权限控制细节分析)
- 如何挑选云服务器(高质量的美国云服务器选择方法有哪些?)
排行榜
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9