Ad Widget

Collapse

How to create a dashboard for showing the hosts currently on maintenance mode

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • sambhu.prakash
    Junior Member
    • Apr 2021
    • 20

    #1

    How to create a dashboard for showing the hosts currently on maintenance mode

    Hi All,

    Apart from the option to list down Active maintenance periods, is there a way to list down the hosts that had successfully entered in the maintenance mode? What I am looking for is a possible dashboard widget to use so people can come look at the dash and quickly see which hosts are on maintenance currently as per the active maintenance period rule. Monitoring >> Hosts can list all hosts including hosts that are on maintenance, but what I am looking for is something exclusive for hosts that are on maintenance mode. May be a radio button to flip between on and off instead of check box on the Monitoring >> Hosts would also help.
    Click image for larger version

Name:	zabbix-maintenance.png
Views:	2028
Size:	27.0 KB
ID:	453741
    With more than 2K hosts, the current options isn't helping much for us.

    Thanks.
  • Check_MK
    Junior Member
    • Jan 2024
    • 1

    #2
    New to Zabbix and I ran into the same problem. Apparently some Zabbix users in the past used a host group for this, so I tried that as well.

    When I set maintenance, I also add the host to the maintenance host group while keeping it in it's original group.
    When I stop maintenance, I remove it from the maintenance host group.

    Still need to check out the API to ease this process, but this is very flexible with alerting and displaying.
    Actually, if you don't set maintenance and only use the maintenance host group for this, you can easily see the alerts for the hosts in maintenance - just filter on the maintenance host group.

    Comment

    • Clontarf[X]
      Member
      • Jan 2017
      • 80

      #3
      Create a custom item that queries either the Zabbix DB or the Zabbix API. Put that value into a widget on your dashboard.

      Comment

    • sambhu.prakash
      Junior Member
      • Apr 2021
      • 20

      #4
      Thanks @Check_MK​, Unfortunately, I don't this its feasible for my setup to use Host group as an option even though it sounds like a plan.

      @Clontarf[X]​, Could you please elaborate on your suggestion of having a custom item. Doesn't looks like I might have explored that path yet. Would you be able to give me a sample? I am more interested to see how the API requests could be created as a custom item. I already tried a Zabbix internal check to pull the maintenance status of each hosts. I could create a Trigger for the same and show those corresponding triggers on the dash. But we at times would do "without data collection maintenance" as well so it would be more appropriate for me to create an API item with "maintenance.get". Just not sure how to integrate it as an item on Zabbix.
      Last edited by sambhu.prakash; 17-01-2024, 17:14.

      Comment

      Working...