zabbix监控之mysql的galera集群状态

根据下面命令,实现对应脚本;


当前集群个数:wsrep_cluster_size           | 3 

当前节点状态:wsrep_connected              | ON

查看集群有哪些节点:mysql> show  global status like 'wsrep_incoming_addresses';
+--------------------------+-------------------------------------------------------------+
| Variable_name            | Value                                                       |
+--------------------------+-------------------------------------------------------------+
| wsrep_incoming_addresses | 10.199.212.176:3306,10.199.212.174:3306,10.199.212.172:3306 |
+--------------------------+-------------------------------------------------------------+
1 row in set (0.00 sec)

mysql> 


查看所有galera状态:mysql> show  global status like '%wsrep%';

你可能感兴趣的:(c基础)