Ad Widget

Collapse

Support for dynamic assignment of prototypes on the same graph prototype

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • pmarini
    Junior Member
    • Jan 2024
    • 9

    #1

    Support for dynamic assignment of prototypes on the same graph prototype

    I'm doing some HTTP agent analysis on my web server and I'm trying to produce a widget with a pie chart that shows the number of hits per HTTP agent in a given time period.

    The log processing script produces the following JSON:

    Code:
    {"user_agent":
        {
         "agent1": 10,
         "agent2": 20,
         ....
        }
    }
    and, via item prototypes, I can create 1 item per HTTP agent. Note that the HTTP agent list is dynamic, as HTTP agent names can be added / removed on each new run.

    I want to display the count for all the agents in a pie chart but I don't know how with graph prototypes (with plain items this is easy to achieve, but you have to "hardcode" the list of HTTP agents, that is dynamical). I see that in Graph prototypes I can add several times the Item protoype and define the Graph type as Pie, but then the graph is broken in the Dashboard.

    The general question is whether it is supported to dynamically put several item prototypes on the same graph prototype?

    Using Zabbix server: 6.4.10
    Last edited by pmarini; 05-01-2024, 22:29.
  • cyber
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • Dec 2006
    • 4807

    #2
    IIRC you cannot add "all discovered items" to same graph via prototype... it creates graph per discovered item.. I am pretty sure there is some dev request about it, but I am too lazy to search...

    Comment

    • pmarini
      Junior Member
      • Jan 2024
      • 9

      #3
      Thanks cyber for your hint, I found the tracking item in support.zabbix.com: https://support.zabbix.com/browse/ZBXNEXT-927​

      Comment

      • Ace
        Junior Member
        • Jun 2021
        • 10

        #4
        There is an even more basic problem, graph prototypes count as duplicates even with an LLD macro in the name, which will create non-duplicate graphs anyway. Seems like the old graph functionality is left in the dust, even though there are tons of use cases where the new one doesn't work at all.

        Comment

        Working...