show status like wsrep_cluster_status ;+----------------------+-------------+| Variable_name | Value |+..."/>
您好,登錄后才能下訂單哦!
MariaDB [(none)]> show status like 'wsrep_cluster_status';
+----------------------+-------------+
| Variable_name | Value |
+----------------------+-------------+
| wsrep_cluster_status | non-Primary |
+----------------------+-------------+
1 row in set (0.001 sec)
MariaDB [(none)]> SET GLOBAL wsrep_provider_options='pc.bootstrap=true';
Query OK, 0 rows affected (0.004 sec)
MariaDB [(none)]> show status like 'wsrep_cluster_status';
+----------------------+---------+
| Variable_name | Value |
+----------------------+---------+
| wsrep_cluster_status | Primary |
+----------------------+---------+
1 row in set (0.001 sec)
MariaDB [(none)]> exit
Bye
[oracle@204_maridb mysql]$
確保其它集群關閉的情況下,使節(jié)點正常
SET GLOBAL wsrep_provider_options='pc.bootstrap=true';
其它節(jié)點執(zhí)行
/usr/bin/mysqld_safe --wsrep-recover
根據錯誤日志獲取掉線時的seqno
修改參數文件 grastates.dat
vi grastates.dat
--如果此seqno 大于存活節(jié)點的wsrep_local_cached_downto值,
--直接啟動mysql服務
systemctl start mysql
注意:
A 節(jié)點存活,B節(jié)點加入后,C節(jié)點加入時需要指定A作為 sst的donor
在A節(jié)點執(zhí)行 show global variables like '%node_name%';
mysqld_safe --wsrep_sst_donor=nodeA
免責聲明:本站發(fā)布的內容(圖片、視頻和文字)以原創(chuàng)、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯(lián)系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。