Ad Widget

Collapse

macro doe's not work for cpu load check

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • TASSA
    Junior Member
    • Dec 2014
    • 27

    #1

    macro doe's not work for cpu load check

    Hello Guys
    Im a newbie in zabbix
    I HAVE A MAP And i"m trying to set up a macro that checks fortigate FIREWALL cpu load but no success yet
    im getting

    THIS IS THE MACRO im setting
    "CPU: {{HOST.HOST}:fgProcessorSysUsage[,avg1].last(0)}

    and this is what i get
    cpu:*UNKNOWN*

    Any help willbe approcitae
    Tia
    Tal









    (i have uploadded and associate a CPU-TEMPLATE FOR FORTIGATE with my host)
    Last edited by TASSA; 09-12-2014, 18:08.
  • aib
    Senior Member
    • Jan 2014
    • 1615

    #2
    "CPU: {{HOST.HOST}:fgProcessorSysUsage[.avg1].last(0)}"

    Are you absolutely sure that BEFORE avg1 you have to use Period (.) instead of Comma (,) ?

    My expression looks like
    Code:
    CPU Load: {{HOST.HOST}:system.cpu.load[percpu,avg15].last(0)}
    As you can see, I use ",avg15" and it works.
    Sincerely yours,
    Aleksey

    Comment

    • TASSA
      Junior Member
      • Dec 2014
      • 27

      #3
      Originally posted by aib
      "CPU: {{HOST.HOST}:fgProcessorSysUsage[.avg1].last(0)}"

      Are you absolutely sure that BEFORE avg1 you have to use Period (.) instead of Comma (,) ?

      My expression looks like
      Code:
      CPU Load: {{HOST.HOST}:system.cpu.load[percpu,avg15].last(0)}
      As you can see, I use ",avg15" and it works.
      yes you are right i made a typo mistake (.) but its is now with comma as u suggested but i still get the same result
      CPU LOAD *unknown*

      this is the new syntex as u suggetsed ( im using my cpu key !!
      CPU Load: {{HOST.HOST}:fgSysCpuUsage[percpu,avg15].last(0)}

      Comment

      • aib
        Senior Member
        • Jan 2014
        • 1615

        #4
        It's better to have the exact name of Item which you would like to see on the Map.

        For example, I found out that in template "zbx-fortinet-cpu.xml" exist one discovery Item with name "fgSysCpuUsage" and description "System CPU Usage"

        So, the formula will look like
        Code:
        CPU Load: {{HOST.HOST}:fgSysCpuUsage.last(0)}
        As you can notice - there is NO any additional suffixes for fgSysCpuUsage: you don't need to add "[,avg5]" or "[percpu,avg15]", because it doesn't exist in original key for Item.
        Sincerely yours,
        Aleksey

        Comment

        Working...