SNMP Messages

 

 

THIS DOCUMENT PROVIDES INFORMATION WITH RESPECT TO DIFFERENT SNMP MESSAGES AND WHAT ALL SNMP MESSAGES DOES VEGA SUPPORTS

SNMP Messages

Table as given below shows the list of SNMP Messages and whether they are supported in VEGA or not.

Sl. No.

SNMP Message

VEGA Support
(Y/N)

1

SNMP Trap

Y

2

SNMP Get

Y

3

SNMP Set

Y

4

SNMP GetNext

Y

5

SNMP GetBulk

Y

6

SNMP Walk

Y

7

SNMP InformRequest

N

8

SNMP Response

Y

Please find the description and example with respect to all SNMP messages as supported by VEGA:

SNMP Trap

This message is initiated by an SNMP Agent and sent to the SNMP Manager. For example, the VEGA (SNMP Agent) could send a message to the SNMP Manager that VEGA has went down and restarted.
This is termed an SNMP Trap. Basically, it is an alarm telling the Manager that the VEGA has been restarted.

It can also be used by network entities to signal abnormal conditions to management stations. A "cold-trap" is sent when device hard reboots, and in case device performs a software reload a "warm-trap" is sent to the manager on start-up.

Below pcap trace image shows the SNMP TRAP triggered by VEGA when VEGA box comes up after reboot (COLD START):

SNMP Get

This message is initiated by the SNMP Manager when it wants to retrieve some data from an SNMP Agent. SNMP GET is a request to query for information on a network entity. One or more object identifiers (OIDs) may be given as arguments on the command line in case of using snmpget application or Manager may send more than one OID's in its SNMP GETrequest.

For example as given below:

SNMP Get Command

SNMP Get For SNMPv1

snmpget -v1 -c public 192.168.3.199 1.3.6.1.2.1.1.6

 

SNMP Get For SNMPv2c

snmpget -v2c -c public 192.168.3.199 1.3.6.1.2.1.1.6

 

SNMP Get For SNMPv3

snmpget -v3 -u public -c public 192.168.3.199 1.3.6.1.2.1.1.6

Below pcap trace image shows the SNMP GET Request received at vega and VEGA sending response for the same.

SNMP SET

(As of now only supported for sysLocation and sysContact) This message is initiated by the SNMP Manager that is sent when the operator wants to change data on a network element i.e. modify information on the remote host

For example as given below:

SNMP Set Command For SNMPv2c

snmpset -v2c -c public 192.168.3.199 1.3.6.1.2.1.1.6 s "sangoma"

Below pcap trace image shows the SNMP SET Request received at vega and VEGA sending response for the same.

Each message sent between the SNMP Agent and the SNMP Manager makes reference to a specific object. For example, requesting FAN status is requesting the status of the object which is a FAN.
These objects have an address or number associated with them. The number is referred to as an OID (Object Identifier).
A series of OIDs in a specific area are considered the MIB (Management Information Base).

 

Important NOTE

Only Contact and Location Variables are set permanently on VEGA using set command and will not get reset even if the device is rebooted.

SNMP GetNext

This message is initiated by the SNMP Manager when it wants to retrieve some data from an SNMP Agent of the next variable for which request has been sent. Returns a Response with variable binding for the next variable in the MIB. The entire MIB of an agent can be walked by iterative application of GetNextRequest starting at OID 0. Rows of a table can be read by specifying column OIDs in the variable bindings of the request.

 It is mainly request to query a network entity efficiently for information, , is used to retrieve the next oid in the mib tree of data.

For example as given below:

SNMP GetNext Command for SNMPv2c

snmpgetnext -m all -v2c -c public 192.168.3.199 1.3.6.1.2.1.2.2.1.1

Below pcap trace image shows the SNMP GETNEXT Request received at vega and VEGA sending response for the same.

SNMP GetBulk

This message is initiated by the SNMP Manager when it wants to retrieve data from SNMP Agent. This is basically a multiple iteration of GetNext Request untill t reached to the maximum limit which SNMP Agent can sent in a single SNMP Response. Returns a Response with multiple variable bindings walked from the variable binding or bindings in the request. PDU specific non-repeaters and max-repetitions fields are used to control response behavior and is introduced in SNMPv2. Max-repetitions mainly shows number of variable binding does the SNMP GetBulk request needs to retrieve from VEGA.

For example as given below where snmpbulkget application is used to get response from SNMP Agent i.e. VEGA:

SNMP Bulk Get Command for SNMPv2c

snmpbulkget -m all -v2c -c public 192.168.3.199 -C r1000 system

Important Information

In case of SNMP GetBulk request, VEGA will sent the response with data of all binding variables as requested by SNMP Manager if it does not reaches to the Maximum size limit of SNMP response which SNMP Agent (VEGA) is allowed to send.

In case if SNMP response has reached to Maximum size limit of the response message and Max-repetitions as received within SNMP BulkGet request from SNMP Manager is too high then, VEGA will send the SNMP response with data of all binding variables accumulated until the maximum response size limit has been reached.

NOTE

In above mentioned snmpbulkget command:

  • Agent IP: 192.168.3.199 ,

  • -v: SNMP version to use

  • -c: community string

  • r: number of OID to fetch


Below pcap trace image shows the SNMP BULKGET Request received at vega and VEGA sending response for the same.

SNMP Walk

snmpwalk is an SNMP application that uses SNMP GETNEXT requests to query a network entity for a tree of information. An object identifier (OID) may be given on the command line.This OID specifies which portion of the object identifier space will be searched using GETNEXT requests

For example as given below where snmpwalk application is used to get response from SNMP Agent i.e. VEGA:

SNMPWALK Command For SNMPv2c

snmpwalk -v2c -c public 192.168.3.199

SNMP Message Format

Each SNMP message contains the following:

  • Version Number

  • Community Name (password)

  • One or more SNMP PDU's (Protocol Data Units or SNMP messages)
     

An SNMP message also contains the following: (All messages other than traps)

  • request id

  • error status

  • error index

  • list of OIDs and values
     

A Trap (alarm) contains the following:

  • enterprise

  • generic trap id

  • specific trap id

  • time stamp

  • list of OIDs and values

Return to Documentation Home I Return to Sangoma Support