ubuntu-14.04 - 错误 Galer 集群 : Failed to read 'ready <addr>' from: wsrep_sst_rsync --role 'joiner'

标签 ubuntu-14.04 cluster-computing mariadb rsync galera

你可以帮助我吗..我是 mariadb 集群的新手。当我开发新的 galera 集群时,当我重新启动其中一个集群时出现错误:无法从以下位置读取“ready”:wsrep_sst_rsync --role 'joiner'

Thera 是五服务器

这是我的galera.cnf

[mysqld]
binlog_format=ROW
default-storage-engine=innodb
innodb_autoinc_lock_mode=2
#bind-address=0.0.0.0

# Galera Provider Configuration
wsrep_on=ON
wsrep_provider=/usr/lib/galera/libgalera_smm.so

# Galera Cluster Configuration
wsrep_cluster_name="dev_cluster"
wsrep_cluster_address="gcomm://192.168.0.18,192.168.0.19,192.168.0.20,192.168.0.22,192.168.0.23"

# Galera Synchronization Configuration
wsrep_sst_method=rsync

# Galera Node Configuration
wsrep_node_address="192.168.0.20"
wsrep_node_name="galera_node5"

这是我的主人

root@ubuntu:/home/sysop# cat /etc/hosts
127.0.0.1   localhost
127.0.1.1   ubuntu
192.168.0.22    galera_node02
192.168.0.23    galera_node03
192.168.0.20    galera_node05
192.168.0.18    galera_node01
192.168.0.19    galera_node04

# The following lines are desirable for IPv6 capable hosts
::1     localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters

这是错误

Mar 17 10:59:43 ubuntu mysqld: 2017-03-17 10:59:43 140269156558592 [Note] WSREP: STATE EXCHANGE: got state msg: 25f209f2-0ac6-11e7-a30a-72f072c45c2c from 1 (galera_node5)
Mar 17 10:59:43 ubuntu mysqld: 2017-03-17 10:59:43 140269156558592 [Note] WSREP: Quorum results:
Mar 17 10:59:43 ubuntu mysqld: #011version    = 4,
Mar 17 10:59:43 ubuntu mysqld: #011component  = PRIMARY,
Mar 17 10:59:43 ubuntu mysqld: #011conf_id    = 1,
Mar 17 10:59:43 ubuntu mysqld: #011members    = 1/2 (joined/total),
Mar 17 10:59:43 ubuntu mysqld: #011act_id     = 8908,
Mar 17 10:59:43 ubuntu mysqld: #011last_appl. = -1,
Mar 17 10:59:43 ubuntu mysqld: #011protocols  = 0/7/3 (gcs/repl/appl),
Mar 17 10:59:43 ubuntu mysqld: #011group UUID = 8e2b23f2-0988-11e7-8187-17fbd8273067
Mar 17 10:59:43 ubuntu mysqld: 2017-03-17 10:59:43 140269156558592 [Note] WSREP: Flow-control interval: [23, 23]
Mar 17 10:59:43 ubuntu mysqld: 2017-03-17 10:59:43 140269156558592 [Note] WSREP: Shifting OPEN -> PRIMARY (TO: 8908)
Mar 17 10:59:43 ubuntu mysqld: 2017-03-17 10:59:43 140269486971648 [Note] WSREP: State transfer required: 
Mar 17 10:59:43 ubuntu mysqld: #011Group state: 8e2b23f2-0988-11e7-8187-17fbd8273067:8908
Mar 17 10:59:43 ubuntu mysqld: #011Local state: 8e2b23f2-0988-11e7-8187-17fbd8273067:8828
Mar 17 10:59:43 ubuntu mysqld: 2017-03-17 10:59:43 140269486971648 [Note] WSREP: New cluster view: global state: 8e2b23f2-0988-11e7-8187-17fbd8273067:8908, view# 2: Primary, number of nodes: 2, my index: 1, protocol version 3
Mar 17 10:59:43 ubuntu mysqld: 2017-03-17 10:59:43 140269486971648 [Warning] WSREP: Gap in state sequence. Need state transfer.
Mar 17 10:59:43 ubuntu mysqld: 2017-03-17 10:59:43 140269139785472 [Note] WSREP: Running: 'wsrep_sst_rsync --role 'joiner' --address '192.168.0.20' --datadir '/var/lib/mysql/'   --parent '2720' --binlog '/var/log/mysql/mariadb-bin' '
Mar 17 10:59:43 ubuntu mysqld: 2017-03-17 10:59:43 140269139785472 [ERROR] WSREP: Failed to read 'ready <addr>' from: wsrep_sst_rsync --role 'joiner' --address '192.168.0.20' --datadir '/var/lib/mysql/'   --parent '2720' --binlog '/var/log/mysql/mariadb-bin' 
Mar 17 10:59:43 ubuntu mysqld: #011Read: '(null)'
Mar 17 10:59:43 ubuntu mysqld: 2017-03-17 10:59:43 140269139785472 [ERROR] WSREP: Process completed with error: wsrep_sst_rsync --role 'joiner' --address '192.168.0.20' --datadir '/var/lib/mysql/'   --parent '2720' --binlog '/var/log/mysql/mariadb-bin' : 2 (No such file or directory)
Mar 17 10:59:43 ubuntu mysqld: 2017-03-17 10:59:43 140269486971648 [ERROR] WSREP: Failed to prepare for 'rsync' SST. Unrecoverable.
Mar 17 10:59:43 ubuntu mysqld: 2017-03-17 10:59:43 140269486971648 [ERROR] Aborting
Mar 17 10:59:43 ubuntu mysqld: 
Mar 17 10:59:43 ubuntu kernel: [  273.896861] audit: type=1400 audit(1489723183.985:18): apparmor="DENIED" operation="exec" profile="/usr/sbin/mysqld" name="/bin/dash" pid=2738 comm="mysqld" requested_mask="x" denied_mask="x" fsuid=105 ouid=0
Mar 17 10:59:57 ubuntu mysqld: Error in my_thread_global_end(): 1 threads didn't exit
Mar 17 10:59:57 ubuntu mysqld_safe: mysqld from pid file /var/run/mysqld/mysqld.pid ended
Mar 17 11:00:41 ubuntu /etc/init.d/mysql[3263]: 0 processes alive and '/usr/bin/mysqladmin --defaults-file=/etc/mysql/debian.cnf ping' resulted in
Mar 17 11:00:41 ubuntu /etc/init.d/mysql[3263]: #007/usr/bin/mysqladmin: connect to server at 'localhost' failed
Mar 17 11:00:41 ubuntu /etc/init.d/mysql[3263]: error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (111 "Connection refused")'
Mar 17 11:00:41 ubuntu /etc/init.d/mysql[3263]: Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists!
Mar 17 11:00:41 ubuntu /etc/init.d/mysql[3263]: 
Mar 17 11:09:01 ubuntu CRON[3284]: (root) CMD (  [ -x /usr/lib/php/sessionclean ] && if [ ! -d /run/systemd/system ]; then /usr/lib/php/sessionclean; fi)

这是我的 iptables:

root@ubuntu:/home/sysop# iptables -S
-P INPUT DROP
-P FORWARD ACCEPT
-P OUTPUT ACCEPT
-A INPUT -i lo -j ACCEPT
-A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
-A INPUT -s 192.168.0.0/26 -p tcp -m tcp --dport 22 -m conntrack --ctstate NEW,ESTABLISHED -j ACCEPT
-A INPUT -s 192.168.0.0/24 -i eth0 -p icmp -m icmp --icmp-type 8 -j ACCEPT
-A INPUT -s 192.168.0.0/24 -i eth0 -p tcp -m tcp --dport 3306 -j ACCEPT
-A INPUT -s 192.168.0.0/24 -i eth0 -p tcp -m tcp --dport 4567 -j ACCEPT
-A INPUT -s 192.168.0.0/24 -i eth0 -p tcp -m tcp --dport 4568 -j ACCEPT
-A INPUT -s 192.168.0.0/24 -i eth0 -p tcp -m tcp --dport 4444 -j ACCEPT
-A INPUT -s 192.168.0.0/24 -i eth0 -p udp -m udp --dport 4567 -j ACCEPT

有人可以帮忙吗?

非常感谢

最佳答案

当我尝试使用日志文件中显示的参数手动运行 wsrep_sst_rsync 时,我发现了同样的问题并得到了解决方案。 就我而言,是: wsrep_sst_rsync --角色'加入者'--地址'10.0.1.82'--datadir'/var/lib/mysql/'--defaults-file'/etc/mysql/my.cnf'--defaults-group-suffix' ' --父'5048' ''

这表明有一个 rsync 进程已经在监听端口 4444。杀死它可以解决问题。

关于ubuntu-14.04 - 错误 Galer 集群 : Failed to read 'ready <addr>' from: wsrep_sst_rsync --role 'joiner' ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42849244/

相关文章:

linux - 如何能够 "move"移动到新机器时脚本所需的所有必要库

php - 获取下一个 MYSQL 条目并保留我的订单

php - Select MySQL 出现重复条目​​ - 非常奇怪

ubuntu-14.04 - Ubuntu : Do NOT lock the screen when pressing Super+L

swift - 在 ubuntu 14.04 中快速安装时出错

node.js - 与 nginx 的 10K 并发连接

r - 安装 R 包 readRDS(file) 中出现错误 : error reading from connection

hadoop - 在hadoop集群中,hive应该安装在所有节点上吗?

c# - 我怎样才能像在终端上一样获取集群信息,但在我的 c# 客户端 (stackexchange) 上?

sql - 重新排序数据库中的行