Forum Discussion

Nik's avatar
Nik
Icon for Cirrus rankCirrus
Aug 22, 2015

monitoring snmp pool/virtual throughput (per object)

i'm having trouble finding the oid for requests per sec or bytes/bits per sec per pool/virtual.. not overall. does such a thing exist?

 

the closest i've found is the total, not the current rate.

 

5 Replies

  • We calculate this by taking ie. the delta value of transferred bytes/bits and dividing it with the polling interval.

     

    Ie. with an interval of 10 seconds the equation would be ("This value" - "Previous value")/10.

     

    Which client are you using?

     

    /Patrik

     

  • i'm writing a datadog ( http://www.datadoghq.com/ ) integration (uses pysnmp) and this is the only metric that's given me problems so far. you're saying that to get requests/sec or bytes/sec i need to know the previous value and the timestamp of the previous value?

     

    as far as i'm aware neither the standard polling client nor the datadog graphing ui allows me access to that data directly. as an alternate option i could write a stand-alone monitor that pushes the same data but keeps the previous timestamp and value in memory to do what (i think) you're describing.

     

  • Yeah, we're using Zabbix and it has something called calculated items. You don't necessarily need to know the timestamp but rather the interval you're doing the polling.

     

    Let's say you make one request every 10 seconds and your current total client throughput for the virtual server you're polling is 10kb. 10 seconds later you're polling again and get 20kb.

     

    20kb-10kb=10kb (the VS has had a client throughput of a total 10 kb during these 10 seconds)

     

    To get the average kb per second you then divide this with 10 and get 1kb/second.

     

    Hope that's clearer.

     

    /Patrik

     

  • yeah i understand that we can calculate rate ourselves by using the current and previous total.. i'm just disappointed that all i can pull from snmp is totals - i was really looking for a rate oid.

     

  • Hamish's avatar
    Hamish
    Icon for Cirrocumulus rankCirrocumulus

    A rate would be pretty much unhelpful... It changes. And you'd have little or no control over how long the rate was calculated. You'd be at the whim of whichever developer/designer decided to use. They might like a 5 minute average (Shades of Cisco SNMP stats for CPU). But 5 minutes isn't good enough. They might like a 10 second average, but you only poll every 60 seconds... So you lose 5/6ths of the data.

     

    Yes, you could conceivably save the data every second internally to the SNMPD and accept a value for making the calculation. But the S in SNMP is for SIMPLE.

     

    Polling for totals and calculating the difference/polltime is the only way you can make your own decisions on frequency and be accurate.

     

    H