3 MIB files
Introduction
For example,
is textual representation of OID
You can use either, when monitoring SNMP devices with Zabbix, but if you feel more comfortable when using textual representation you have to install MIB files.
Installing MIB files
On Debian-based systems:
# download-mibs
On RedHat-based systems:
Enabling MIB files
# As the snmp packages come without MIB files due to license reasons, loading
# loading them by commenting out the following line.
#mibs :
Testing MIB files
Testing snmp MIBs can be done using snmpwalk
utility. If you don’t have it installed, use the following instructions.
On Debian-based systems:
# apt install snmp
On RedHat-based systems:
After that, the following command must not give error when you query a network device:
$ snmpwalk -v 2c -c public <NETWORK DEVICE IP> ifInOctets
IF-MIB::ifInOctets.2 = Counter32: 0
IF-MIB::ifInOctets.3 = Counter32: 240375057
IF-MIB::ifInOctets.4 = Counter32: 220893420
[...]
Using MIBs in Zabbix
The most important to keep in mind is that Zabbix processes do not get informed of the changes made to MIB files. So after every change you must restart Zabbix server or proxy, e. g.:
# service zabbix-server restart
Using custom MIB files
There are standard MIB files coming with every GNU/Linux distribution. But some device vendors provide their own.
Let’s say, you would like to use CISCO-SMI MIB file. The following instructions will download and install it:
Now you should be able to use it. Try to translate the name of the object ciscoProducts from the MIB file to OID:
.1.3.6.1.4.1.9.1
If you receive errors instead of the OID, ensure all the previous commands did not return any errors.
The object name translation worked, you are ready to use custom MIB file. Note the MIB name prefix (CISCO-SMI::) used in the query. You will need this when using command-line tools as well as Zabbix.
Keep in mind that MIB files can have dependencies. That is, one MIB may require another. In order to satisfy these dependencies you have to install all the affected MIB files.