Zabbix – Número de triggers com status problem
Indicador de problema com valor total para podermos ter visão do ambiente no todo. Neste caso ele irá apresentar o valor total de triggers em alerta em todas as prioridades: Discussão: Monitoring_triggers_active 1 – Consultas no banco que retornam o resultado
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
SELECT count(t.triggerid) AS TRIGGERS_ACTIVE FROM triggers t, functions f, items i, hosts h WHERE t.triggerid=f.triggerid AND f.itemid=i.itemid AND i.status=0 AND i.hostid=h.hostid AND h.status=0 AND t.status=0 AND t.value=1; SELECT count(DISTINCT t.triggerid) AS TRIGGERS_ACTIVE FROM triggers t, functions f, items i, hosts h WHERE t.triggerid=f.triggerid AND f.itemid=i.itemid AND i.status=0 AND i.hostid=h.hostid AND h.status=0 AND t.status=0 AND t.value=1; |
2 – UserParameter
1 2 3 4 5 |
# vim /etc/zabbix/zabbix_agentd.d/userparameter_mysql.conf # echo "SELECT count(DISTINCT t.triggerid) FROM triggers t, functions f, items i, hosts h WHERE t.triggerid=f.triggerid AND f.itemid=i.itemid AND i.status=0 AND i.hostid=h.hostid AND h.status=0 AND t.status=0 AND t.value=1;"|mysql -h 192.168.1.230 zabbix -s -u zabbix UserParameter=trigger.active,echo "SELECT count(DISTINCT t.triggerid) FROM triggers t, functions f, items i, hosts h WHERE t.triggerid=f.triggerid AND f.itemid=i.itemid AND i.status=0 AND i.hostid=h.hostid AND h.status=0 AND t.status=0 AND t.value=1;"|mysql zabbix -s -u zabbix |
3 – Separando a prioridade https://www.zabbix.com/documentation/3.0/manual/api/reference/trigger/object 0…
Continue reading →