SNMPDELTA(1)

πŸ’– SNMPDELTA(1) πŸ’–

okay bestie, welcome to snmpdelta from the Net-SNMP crew β€” it's the manual page, but make it cute. let's get into it πŸ¦‹


✨ NAME ✨

snmpdelta β€” watch the delta differences in SNMP counter values πŸ‘€ (aka: the little changes over time, she's tracking them)


🌸 SYNOPSIS 🌸

snmpdelta [ COMMON OPTIONS ] [-Cf] [ -Ct ] [ -Cs ] [ -CS ] [ -Cm ] [ -CF
configfile ] [ -Cl ] [ -Cp period ] [ -CP Peaks ] [ -Ck ] [ -CT ] AGENT
OID [ OID ... ]

πŸ’… DESCRIPTION πŸ’…

So snmpdelta will monitor the integer valued OIDs you tell it about, and then report the changes over time. that's the whole vibe. she watches, she reports, she serves πŸ“ˆ

AGENT identifies a target SNMP agent, which is instrumented to monitor the given objects. at its simplest, the AGENT spec is just a hostname or an IPv4 address. in that case, the command will try to talk to the agent using UDP/IPv4 to port 161 of the given target host. for the full list of possible formats for AGENT, go read snmpcmd(1) β€” she has the receipts.

OID is an object identifier which uniquely identifies the object type within a MIB. and yes, you can put multiple OIDs on a single snmpdelta command. the more the merrier fr fr πŸŽ€


✨ OPTIONS ✨

🫢 COMMON OPTIONS

please go see snmpcmd(1) for the list of possible values for COMMON OPTIONS and their descriptions. not me outsourcing the lore, but that's where it lives πŸ’œ


  • -Cf β€” don't fix errors and don't retry the request. without this option, if multiple oids were specified for a single request and the request for one or more of those oids fails, snmpdelta will retry the request so that data for the oids apart from the ones that failed still comes back. specifying -Cf tells snmpdelta not to retry a request, even when there are multiple oids specified. she said no take-backs πŸ™ˆ
  • -Ct β€” this flag determines the time interval from the monitored entity.
  • -Cs β€” this flag displays a timestamp. clocking in, as she should πŸ•
  • -CS β€” generates a "sum count" in addition to the individual instance counts. the "sum count" is the total of all the individual deltas for each time period. math girlies rise πŸ”₯
  • -Cm β€” prints the max value ever attained. peak performance, literally πŸ‘‘
  • -CF configfile β€” tells snmpdelta to read its configuration from the specified file. this option lets the input be set up in advance instead of having to be typed out on the command line. prep ahead, main character energy πŸ’…
  • -Cl β€” tells snmpdelta to write its configuration to files whose names correspond to the MIB instances monitored. for example, snmpdelta -Cl localhost ifInOctets.1 will create a file "localhost-ifInOctets.1". journaling era πŸŽ€
  • -Cp β€” specifies the number of seconds between polling periods. polling = sending a request to the agent. the default polling period is one second.
  • -CP peaks β€” specifies the reporting period in number of polling periods. if this option is specified, snmpdelta polls the agent peaks number of times before reporting the results. the result reported includes the average value over the reporting period. on top of that, the highest polled value within the reporting period is shown. average AND the overachiever, we love to see it ✨
  • -Ck β€” when the polling period (-Cp) is an increment of 60 seconds and the timestamp is displayed in the output (-Cs), then the default display shows the timestamp in the format hh:mm mm/dd. this option causes the timestamp format to be hh:mm:ss mm/dd. glow-up for your timestamps πŸ¦‹
  • -CT β€” makes snmpdelta print its output in tabular form. organized queen 🌈
  • -Cv vars/pkt β€” specifies the maximum number of oids allowed to be packaged in a single PDU. multiple PDUs can be created in a single request. the default value of variables per packet is 60. this option is useful if a request response results in an error because the packet is too big. little packets, big feelings πŸ’œ
⚠️ note that snmpdelta REQUIRES an argument specifying the agent to query and at least one OID argument, as described in the snmpcmd(1) manual page. non-negotiable bestie, she needs both 😀

🌟 EXAMPLES 🌟

first one, timestamped and living her best life:

$ snmpdelta -c public -v 1 -Cs localhost IF-MIB::ifInUcastPkts.3 IF-MIB::ifOutUcastPkts.3
[20:15:43 6/14] ifInUcastPkts.3 /1 sec: 158
[20:15:43 6/14] ifOutUcastPkts.3 /1 sec: 158
[20:15:44 6/14] ifInUcastPkts.3 /1 sec: 184
[20:15:44 6/14] ifOutUcastPkts.3 /1 sec: 184
[20:15:45 6/14] ifInUcastPkts.3 /1 sec: 184
[20:15:45 6/14] ifOutUcastPkts.3 /1 sec: 184
[20:15:46 6/14] ifInUcastPkts.3 /1 sec: 158
[20:15:46 6/14] ifOutUcastPkts.3 /1 sec: 158
[20:15:47 6/14] ifInUcastPkts.3 /1 sec: 184
[20:15:47 6/14] ifOutUcastPkts.3 /1 sec: 184
[20:15:48 6/14] ifInUcastPkts.3 /1 sec: 184
[20:15:48 6/14] ifOutUcastPkts.3 /1 sec: 184
[20:15:49 6/14] ifInUcastPkts.3 /1 sec: 158
[20:15:49 6/14] ifOutUcastPkts.3 /1 sec: 158
^C

and now the tabular version, -CT said let's make it a table:

$ snmpdelta -c public -v 1 -Cs -CT localhost IF-MIB:ifInUcastPkts.3 IF-MIB:ifOutcastPkts.3
localhost ifInUcastPkts.3     ifOutUcastPkts.3
[20:15:59 6/14]     184.00    184.00
[20:16:00 6/14]     158.00    158.00
[20:16:01 6/14]     184.00    184.00
[20:16:02 6/14]     184.00    184.00
[20:16:03 6/14]     158.00    158.00
[20:16:04 6/14]     184.00    184.00
[20:16:05 6/14]     184.00    184.00
[20:16:06 6/14]     158.00    158.00
^C

the following example uses a number of options. since the Cl option is specified, the output is sent to a file and not to the screen πŸ“

$ snmpdelta -c public -v 1 -Ct -Cs -CS -Cm -Cl -Cp 60 -CP 60
  interlink.sw.net.cmu.edu .1.3.6.1.2.1.2.2.1.16.3 .1.3.6.1.2.1.2.2.1.16.4

πŸ” SEE ALSO πŸ”

snmpcmd(1), variables(5).


and that's the page, bestie!! go monitor some counters, you absolute icon πŸ’–

this was V5.9.5.2, dated 25 Jul 2003 β€” old but iconic, and still serving. periodt. πŸ‘‘βœ¨

πŸ“¦ where this page comes from