grafana / grafana-zabbix

Zabbix plugin for Grafana dashboard
http://play.grafana-zabbix.org
Apache License 2.0
2.07k stars 457 forks source link

Wrong status for the same alerts on Historical Alerts panel while showing history #1284

Open OCrylic opened 3 years ago

OCrylic commented 3 years ago

Describe the bug
While showing history in Historical Alerts panel, when an alerts occurs several times for a same host, it is showing the last status for all alerts instead of the real status (previous alerts in Resolved status and last alert in Problem status), as you can see in the attached screenshots comparing Zabbix output and Grafana output; ![image](https://user-images.githubusercontent.com/89840295/131481584-34bae8ca-ba83-4a89-a19c-5648d9210a8f.png) ![image](https://user-images.githubusercontent.com/89840295/131481985-d51cd04f-dd48-417f-a9fa-40dfa5a99437.png)

Software versions

Grafana | Zabbix | Grafana-Zabbix Plugin -- | -- | -- 7.5.9 | 5.2.7 | 4.1.5
OCrylic commented 2 years ago

I did not received any update on this issue, is there something missing in the template or description ?

dvaltmoli commented 1 year ago

Same problem here. In Zabbix, everything works as expected, but in Grafana, the Zabbix problems panel shows the last trigger state instead of the event state. This is why old resolved events are displayed in wrong state if the same trigger raise again.

zabbix grafana

Upon inspecting the API calls in the browser's developer mode, I noticed that the calls being made are 'trigger.get' and 'problem.get,' instead of 'event.get,' which would provide the real state of the problem event.

trigger get problem get

Zabbix documentation

Software version Grafana Zabbix Plugin
10.0.3 6.4.4 4.3.1
ronivay commented 3 months ago

Hey. Any updates on this? Looks like the plugin is querying events and triggers nowadays, but still seems to show past events as active if the trigger is same. In addition to this fix, i'd love to see the possibility to show event duration which might be very different than the age calculated from the even time and recovery time.

minhyukz commented 2 months ago

Hi, I hope this bug is fixed.