Zabbix Documentation 1.8

2.23.04.0 (current)In development:4.2 (devel)Unsupported:1.82.02.43.23.4

User Tools

Site Tools


Sidebar

manual:advanced_snmp

12 Advanced SNMP Monitoring

1 Special OIDs

Some of the most used SNMP OIDs are translated automatically to a numeric representation by Zabbix. For example, ifIndex is translated to 1.3.6.1.2.1.2.2.1.1, ifIndex.0 is translated to 1.3.6.1.2.1.2.2.1.1.0.

The table contains list of the special OIDs.

Special OIDIdentifierDescription
ifIndex1.3.6.1.2.1.2.2.1.1A unique value for each interface.
ifDescr1.3.6.1.2.1.2.2.1.2A textual string containing information about the interface.This string should include the name of the manufacturer, the product name and the version of the hardware interface.
ifType1.3.6.1.2.1.2.2.1.3The type of interface, distinguished according to the physical/link protocol(s) immediately 'below' the network layer in the protocol stack.
ifMtu1.3.6.1.2.1.2.2.1.4The size of the largest datagram which can be sent / received on the interface, specified in octets.
ifSpeed1.3.6.1.2.1.2.2.1.5An estimate of the interface's current bandwidth in bits per second.
ifPhysAddress1.3.6.1.2.1.2.2.1.6The interface's address at the protocol layer immediately `below' the network layer in the protocol stack.
ifAdminStatus1.3.6.1.2.1.2.2.1.7The current administrative state of the interface.
ifOperStatus1.3.6.1.2.1.2.2.1.8The current operational state of the interface.
ifInOctets1.3.6.1.2.1.2.2.1.10The total number of octets received on the interface, including framing characters.
ifInUcastPkts1.3.6.1.2.1.2.2.1.11The number of subnetwork-unicast packets delivered to a higher-layer protocol.
ifInNUcastPkts1.3.6.1.2.1.2.2.1.12The number of non-unicast (i.e., subnetwork- broadcast or subnetwork-multicast) packets delivered to a higher-layer protocol.
ifInDiscards1.3.6.1.2.1.2.2.1.13The number of inbound packets which were chosen to be discarded even though no errors had been detected to prevent their being deliverable to a higher-layer protocol. One possible reason for discarding such a packet could be to free up buffer space.
ifInErrors1.3.6.1.2.1.2.2.1.14The number of inbound packets that contained errors preventing them from being deliverable to a higher-layer protocol.
ifInUnknownProtos1.3.6.1.2.1.2.2.1.15The number of packets received via the interface which were discarded because of an unknown or unsupported protocol.
ifOutOctets1.3.6.1.2.1.2.2.1.16The total number of octets transmitted out of the interface, including framing characters.
ifOutUcastPkts1.3.6.1.2.1.2.2.1.17The total number of packets that higher-level protocols requested be transmitted, and which were not addressed to a multicast or broadcast address at this sub-layer, including those that were discarded or not sent.
ifOutNUcastPkts1.3.6.1.2.1.2.2.1.18The total number of packets that higher-level protocols requested be transmitted, and which were addressed to a multicast or broadcast address at this sub-layer, including those that were discarded or not sent.
ifOutDiscards1.3.6.1.2.1.2.2.1.19The number of outbound packets which were chosen to be discarded even though no errors had been detected to prevent their being transmitted. One possible reason for discarding such a packet could be to free up buffer space.
ifOutErrors1.3.6.1.2.1.2.2.1.20The number of outbound packets that could not be transmitted because of errors.
ifOutQLen1.3.6.1.2.1.2.2.1.21The length of the output packet queue (in packets).
2009/08/13 11:02 · Alexei

2 Use of dynamic indexes

Dynamic indexes are supported since Zabbix version 1.5.

A special syntax for item OID can be used in order to deal with dynamic data (random IDs of network interfaces, etc). The syntax:

<base OID of data>["index","<base OID of index>","<string to search for>"]

For example, to get the ifInOctets value for the GigabitEthernet0/1 interface on a Cisco device, use the following OID:

ifInOctets["index","ifDescr","GigabitEthernet0/1"]
ParameterDescription
base OID of dataBase OID to use for data retrieval.
indexMethod of processing. Currently one method is supported
index – search for index and append it to the base OID
base OID of indexThe OID will be used to make a lookup for the string.
string to search forThe string is used for exact match with a value when doing lookup. Case sensitive.

Another example, getting memory usage of apache process:

HOST-RESOURCES-MIB::hrSWRunPerfMem["index","HOST-RESOURCES-MIB::hrSWRunPath", "/usr/sbin/apache2"]
...

HOST-RESOURCES-MIB::hrSWRunPath.5376 = STRING: "/sbin/getty"
HOST-RESOURCES-MIB::hrSWRunPath.5377 = STRING: "/sbin/getty"
HOST-RESOURCES-MIB::hrSWRunPath.5388 = STRING: "/usr/sbin/apache2"
HOST-RESOURCES-MIB::hrSWRunPath.5389 = STRING: "/sbin/sshd"
...

Now we have index, 5388. The index will be appended to the Data OID in order to receive value we are interested in:

HOST-RESOURCES-MIB::hrSWRunPerfMem.5388 = INTEGER: 31468 KBytes

Dynamic indexes are cached since Zabbix version 1.6.3.

Using dynamic indexes leads to more SNMP queries in Zabbix versions up to 1.7. Dynamic index lookup and data retrieval is performed in single connection since Zabbix version 1.7.

2009/08/13 11:06 · Alexei