Ad Widget

Collapse

Using {Macro} for Graph "Y axis MAX value" possible?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • singk
    Junior Member
    • Feb 2018
    • 6

    #1

    Using {Macro} for Graph "Y axis MAX value" possible?

    I have been searching this forum and google, but I can't find anything related to this. I am trying to create a Graph in a Template and trying to use Macro value for the "Y axis MAX value", however, it appears that I can't use Macro as it throws an error when I try to apply. Is possible and how?
  • kloczek
    Senior Member
    • Jun 2006
    • 1771

    #2
    As far as I remember zabbix source code "Y axis MAX value" it is scalar (not a string) so to have the possibility to place in this graph metadata string instead of the number it would be necessary to add way deeper change than it may look.
    http://uk.linkedin.com/pub/tomasz-k%...zko/6/940/430/
    https://kloczek.wordpress.com/
    zapish - Zabbix API SHell binding https://github.com/kloczek/zapish
    My zabbix templates https://github.com/kloczek/zabbix-templates

    Comment

    • kloczek
      Senior Member
      • Jun 2006
      • 1771

      #3
      Quick check in source code:

      Code:
      [tkloczko@domek trunk]$ grep -r yaxismax create/src/schema.tmpl 
      FIELD        |yaxismax    |t_double    |'100'    |NOT NULL    |0
      In this case graph uses yaxismax and as you see type is t_double.
      You may try open feature request ticket for this on http://support.zabbix.com/ but IMO it is low chance that it will be implemented quickly.
      http://uk.linkedin.com/pub/tomasz-k%...zko/6/940/430/
      https://kloczek.wordpress.com/
      zapish - Zabbix API SHell binding https://github.com/kloczek/zapish
      My zabbix templates https://github.com/kloczek/zabbix-templates

      Comment

      • singk
        Junior Member
        • Feb 2018
        • 6

        #4
        Originally posted by kloczek
        As far as I remember zabbix source code "Y axis MAX value" it is scalar (not a string) so to have the possibility to place in this graph metadata string instead of the number it would be necessary to add way deeper change than it may look.
        Thank youkloczek.

        Yes I figured feature request probably will not get implement that soon. So far I see some of the request take years. Anyway, I did find an alternate solution and that seems to be working fine.

        - Create an Item as Calculated field in the Template and using {Marco} as the value
        - Create a Graph and assigned the Item as YMAX value


        Comment

        Working...