Services Status
AGENT:
Userparameter = mysqld. Status,/etc/init. d/mysqld status | grep-C running
# Servers agentd restart
Server:
#/Usr/local/bin/zabbix_get-s [Agent IP]-k "mysqld. Status"
MySQLMaster Slave Synchronization
Slave agent:
Userparameter = MySQL. replication, /usr/bin/MySQL-uzabbix-e 'show slave status \ G' | grep-e "slave_io_running | slave_ SQL _running" | awk '{print $2}' | grep-c yes
# Servers agentd restart
Server:
#/Usr/local/bin/zabbix_get-s [Agent IP]-k"MySQL. Replication"
MySQL processlist
Master & slave agent:
Userparameter = mysql. process,/usr/bin/MySQL-uroot-ppassword-SNE "show full processlist" | egrep-V "Sleep | ID | show full processlist" | WC-l
# Servers agentd restart
Server:
#/Usr/local/bin/zabbix_get-s [Agent IP]-k"MySQL. Process"
This article is from the wemux blog, please be sure to keep this source http://wemux.blog.51cto.com/2848943/1440209
Zabbix custom Monitoring Learning