[ERROR] Plugin group_replication reported: '[GCS] Error on opening a connection to ip:port

2024-01-15 16:58

本文主要是介绍[ERROR] Plugin group_replication reported: '[GCS] Error on opening a connection to ip:port,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

内容

  • 问题描述
  • 解决方法
    • centos6
      • 防火墙常用命名
    • centos7
      • firewalld常用命令

问题描述

使用MySQL5.7.24 做组复制实验,模式选择主模式,第一台主模式服务器已配置成功,但是在配置第二台服务器加入到配置的组中时报错:

2018-11-28T10:31:51.423293+08:00 0 [ERROR] Plugin group_replication reported: '[GCS] Error on opening a connection to 192.168.233.136:33061 on local port: 33061.'
2018-11-28T10:31:51.423976+08:00 0 [ERROR] Plugin group_replication reported: '[GCS] Error on opening a connection to 192.168.233.56:33061 on local port: 33061.'
2018-11-28T10:31:51.424072+08:00 0 [ERROR] Plugin group_replication reported: '[GCS] Error connecting to all peers. Member join failed. Local port: 33061'
2018-11-28T10:31:51.424738+08:00 0 [Warning] Plugin group_replication reported: 'read failed'
2018-11-28T10:31:51.478391+08:00 0 [ERROR] Plugin group_replication reported: '[GCS] The member was unable to join the group. Local port: 33061'
2018-11-28T10:32:47.316147+08:00 2 [ERROR] Plugin group_replication reported: 'Timeout on wait for view after joining group'
2018-11-28T10:32:47.316280+08:00 2 [Note] Plugin group_replication reported: 'Requesting to leave the group despite of not being a member'
2018-11-28T10:32:47.316343+08:00 2 [ERROR] Plugin group_replication reported: '[GCS] The member is leaving a group without being on one.'
2018-11-28T10:32:47.316875+08:00 2 [Note] Plugin group_replication reported: 'auto_increment_increment is reset to 1'
2018-11-28T10:32:47.316950+08:00 2 [Note] Plugin group_replication reported: 'auto_increment_offset is reset to 1'
2018-11-28T10:32:47.317598+08:00 7 [Note] Error reading relay log event for channel 'group_replication_applier': slave SQL thread was killed
2018-11-28T10:32:47.317690+08:00 7 [Note] Slave SQL thread for channel 'group_replication_applier' exiting, replication stopped in log 'FIRST' at position 0
2018-11-28T10:32:47.320066+08:00 4 [Note] Plugin group_replication reported: 'The group replication applier thread was killed'

解决方法

经排查,第一台已启动服务器防火墙未关闭,所以需要将33061端口配置在防火墙中或者关闭防火墙即可

centos6

防火墙常用命名

# 查看防火墙状态
service iptables status# 停止防火墙
service iptables stop# 启动防火墙
service iptables start# 重启防火墙
service iptables restart# 永久关闭防火墙
chkconfig iptables off# 永久关闭后重启
chkconfig iptables on

开放33061端口

vim /etc/sysconfig/iptables

在文件中新增

-A INPUT -m state --state NEW -M tcp -p tcp --dport 33061 -j ACCEPT

保存后重启防火墙

service iptables restart

centos7

firewalld常用命令

# 启动 
systemctl start firewalld
# 关闭
systemctl stop firewalld
# 查看状态
systemctl status firewalld 
# 开机禁用 
systemctl disable firewalld
# 开机启用
systemctl enable firewalld
# 查看所有打开的端口
firewall-cmd --zone=public --list-ports

开放33061端口

#  --permanent永久生效,没有此参数重启后失效
firewall-cmd --zone=public --add-port=33061/tcp --permanent

重新载入防火墙

firewall-cmd --reload

再次配置第二台服务器就可以了。

这篇关于[ERROR] Plugin group_replication reported: '[GCS] Error on opening a connection to ip:port的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/609589

相关文章

Spring Boot spring-boot-maven-plugin 参数配置详解(最新推荐)

《SpringBootspring-boot-maven-plugin参数配置详解(最新推荐)》文章介绍了SpringBootMaven插件的5个核心目标(repackage、run、start... 目录一 spring-boot-maven-plugin 插件的5个Goals二 应用场景1 重新打包应用

java使用protobuf-maven-plugin的插件编译proto文件详解

《java使用protobuf-maven-plugin的插件编译proto文件详解》:本文主要介绍java使用protobuf-maven-plugin的插件编译proto文件,具有很好的参考价... 目录protobuf文件作为数据传输和存储的协议主要介绍在Java使用maven编译proto文件的插件

Spring Boot 实现 IP 限流的原理、实践与利弊解析

《SpringBoot实现IP限流的原理、实践与利弊解析》在SpringBoot中实现IP限流是一种简单而有效的方式来保障系统的稳定性和可用性,本文给大家介绍SpringBoot实现IP限... 目录一、引言二、IP 限流原理2.1 令牌桶算法2.2 漏桶算法三、使用场景3.1 防止恶意攻击3.2 控制资源

SpringBoot服务获取Pod当前IP的两种方案

《SpringBoot服务获取Pod当前IP的两种方案》在Kubernetes集群中,SpringBoot服务获取Pod当前IP的方案主要有两种,通过环境变量注入或通过Java代码动态获取网络接口IP... 目录方案一:通过 Kubernetes Downward API 注入环境变量原理步骤方案二:通过

maven中的maven-antrun-plugin插件示例详解

《maven中的maven-antrun-plugin插件示例详解》maven-antrun-plugin是Maven生态中一个强大的工具,尤其适合需要复用Ant脚本或实现复杂构建逻辑的场景... 目录1. 核心功能2. 典型使用场景3. 配置示例4. 关键配置项5. 优缺点分析6. 最佳实践7. 常见问题

mysql中的group by高级用法详解

《mysql中的groupby高级用法详解》MySQL中的GROUPBY是数据聚合分析的核心功能,主要用于将结果集按指定列分组,并结合聚合函数进行统计计算,本文给大家介绍mysql中的groupby... 目录一、基本语法与核心功能二、基础用法示例1. 单列分组统计2. 多列组合分组3. 与WHERE结合使

解决Maven项目报错:failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.13.0的问题

《解决Maven项目报错:failedtoexecutegoalorg.apache.maven.plugins:maven-compiler-plugin:3.13.0的问题》这篇文章主要介... 目录Maven项目报错:failed to execute goal org.apache.maven.pl

Java根据IP地址实现归属地获取

《Java根据IP地址实现归属地获取》Ip2region是一个离线IP地址定位库和IP定位数据管理框架,这篇文章主要为大家详细介绍了Java如何使用Ip2region实现根据IP地址获取归属地,感兴趣... 目录一、使用Ip2region离线获取1、Ip2region简介2、导包3、下编程载xdb文件4、J

使用Python实现IP地址和端口状态检测与监控

《使用Python实现IP地址和端口状态检测与监控》在网络运维和服务器管理中,IP地址和端口的可用性监控是保障业务连续性的基础需求,本文将带你用Python从零打造一个高可用IP监控系统,感兴趣的小伙... 目录概述:为什么需要IP监控系统使用步骤说明1. 环境准备2. 系统部署3. 核心功能配置系统效果展

Go语言开发实现查询IP信息的MCP服务器

《Go语言开发实现查询IP信息的MCP服务器》随着MCP的快速普及和广泛应用,MCP服务器也层出不穷,本文将详细介绍如何在Go语言中使用go-mcp库来开发一个查询IP信息的MCP... 目录前言mcp-ip-geo 服务器目录结构说明查询 IP 信息功能实现工具实现工具管理查询单个 IP 信息工具的实现服