Ad Widget

Collapse

SNMP Calulated Item

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Gsmith
    Member
    • Mar 2015
    • 56

    #1

    SNMP Calulated Item

    All,
    I was wonder if anyone could help me out. Trying to get last value of a total value item. I went through this forum and found some examples but they did not work for my needs.

    Where I have look to resoluve my isssue;


    Environment
    OS: CentOS 7
    Zabbix Server Version:Zabbix 4.0.7

    I‘m using a SNMP Item with a calculated Item as shown below.

    SNMP Item;
    Name: Pages Printed Total
    Type: SNMPv2 agent
    Key: .1.3.6.1.4.1.11.2.3.9.4.2.1.4.1.2.7.0
    Update Interval: 1h
    History: 90d
    Trend: 365d

    Calculate Item;
    Name: Pages Printed Last hour
    Type: Calculated
    Key: color.prt.hr
    Formula: last (".1.3.6.1.4.1.11.2.3.9.4.2.1.4.1.2.7.0",3600)
    Update Interval: 1h
    History: 90d
    Trend: 365d

    With this configuration my calculated Item just mirrors the SNMP Item, so the SNMP shows 300 the Calculated item also show 300 even after 3 to 4 hours running without any change.
    How would I be able to just get the Last Hour values from the total amount?
    Any Help would be appreciated,

  • Hamardaban
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • May 2019
    • 2713

    #2
    Just use the change() function that shows the difference between the last and the previous value. with a polling period of 1 hour you will get how many pages were printed per hour.

    Comment

    • Gsmith
      Member
      • Mar 2015
      • 56

      #3
      Hamardaban
      Thank you for the reply. Just make sure I understand you correctly this is what your refering too..


      Click image for larger version

Name:	calculate-item.png
Views:	217
Size:	34.5 KB
ID:	384841

      Comment

      • Gsmith
        Member
        • Mar 2015
        • 56

        #4
        Hamardaban
        Had to make a correction to the Formula change(".1.3.6.1.4.1.11.2.3.9.4.2.1.4.1.2.7.0",360 0). It works now. Thank you for the advice, much apperciated.
        Last edited by Gsmith; 27-08-2019, 23:12.

        Comment


        • Hamardaban
          Hamardaban commented
          Editing a comment
          You welcome!
      Working...