[ZBX-9719] MIB file lookup not described in Zabbix documentation Created: 2015 Jul 21 Updated: 2024 Apr 10 Resolved: 2018 Oct 15 |
|
Status: | Closed |
Project: | ZABBIX BUGS AND ISSUES |
Component/s: | Documentation (D) |
Affects Version/s: | 2.2.6 |
Fix Version/s: | 4.0 (plan) |
Type: | Documentation task | Priority: | Minor |
Reporter: | Sandis Neilands (Inactive) | Assignee: | dimir |
Resolution: | Fixed | Votes: | 0 |
Labels: | mib, snmp | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified |
Team: | |
Sprint: | Sprint 27, Sprint 28, Sprint 29, Sprint 30, Sprint 31, Sprint 32, Sprint 33, Sprint 34, Sprint 35, Sprint 36, Sprint 37, Sprint 38, Sprint 39, Sprint 40, Sprint 41, Sprint 42, Sprint 43 |
Story Points: | 2 |
Description |
MIB file lookup and handling of other system-wide SNMP parameters are not described in Zabbix documentation leading to confusion. For example, in Debian-derived distributions IETF MIBs are not bundled with net-snmp package and must be installed separately. SNMP configuration must be changed for these MIBs to be taken into use by net-snmp commands and programs using net-snmp library. For another example, see the following forum thread. https://www.zabbix.com/forum/showthread.php?t=48856 We should somehow indicate to users that in order to change system-wide SNMP parameters they should look up net-snmp documentation. |
Comments |
Comment by Oleksii Zagorskyi [ 2015 Jul 23 ] |
I was playing with MIBs loading a lot, regarding snmp* commands and snmp traps receiving. We need to be careful with suggestion to load MIB, especially if there are lot of MIBs. The package installs 317 mib files with ~15MB size totally. Btw, recently, at some point a mibs related problem became actual for me (I'm on Debian8/testing), here is solution I've found http://docs.linuxconsulting.mn.it/notes/net-snmp-errors Some possible answer can be here, see for this part from snmptt's snmptt.ini: # Set to 1 to enable the use of the Perl module from the UCD-SNMP / NET-SNMP package. # This is required for $v variable substitution to work, and also for some other options # that are enabled in this .ini file. # Set to 0 to disable the use of the Perl module from the UCD-SNMP / NET-SNMP package. # Note: Enabling this with stand-alone mode can cause SNMPTT to run very slowly due to # the loading of the MIBS at startup. net_snmp_perl_enable = 0 # Set to 1 to enable caching of OID and ENUM translations when net_snmp_perl_enable is # enabled. Enabling this should result in faster translations. # Set to 0 to disable caching. # Note: Restart SNMPTT after updating the MIB files for Net-SNMP, otherwise the cache may # contain inaccurate data. Defaults to 1. net_snmp_perl_cache_enable = 1 The net_snmp_perl_enable parameter allows then to use several other parameters which translates data to more readable forms, see below: # Configures how the OID of the received trap is handled when outputting to a log file / # database. It does NOT apply to the $O variable. # Set to 0 to use the default of numerical OID # Set to 1 to translate the trap OID to short text (symbolic form) (eg: linkUp) # Set to 2 to translate the trap OID to short text with module name (eg: IF-MIB::linkUp) # Set to 3 to translate the trap OID to long text (eg: iso...snmpTraps.linkUp) # Set to 4 to translate the trap OID to long text with module name (eg: # IF-MIB::iso...snmpTraps.linkUp) # Note: -The output of the long format will vary depending on the version of Net-SNMP you # are using. # -net_snmp_perl_enable *must* be enabled # -If using database logging, ensure the trapoid column is large enough to hold the # entire line translate_log_trap_oid = 0 # Configures how OIDs contained in the VALUE of the variable bindings are handled. # This only applies to the values for $n, $+n, $-n, $vn, $+*, $-*. For substitutions # that include variable NAMES ($+n etc), only the variable VALUE is affected. # Set to 0 to disable translating OID values to text (symbolic form) # Set to 1 to translate OID values to short text (symbolic form) (eg: BuildingAlarm) # Set to 2 to translate OID values to short text with module name (eg: UPS-MIB::BuildingAlarm) # Set to 3 to translate OID values to long text (eg: iso...upsAlarm.BuildingAlarm) # Set to 4 to translate OID values to long text with module name (eg: # UPS-MIB::iso...upsAlarm.BuildingAlarm) # For example, if the value contained: 'A UPS Alarm (.1.3.6.1.4.1.534.1.7.12) has cleared.', # it could be translated to: 'A UPS Alarm (UPS-MIB::BuildingAlarm) has cleared.' # Note: net_snmp_perl_enable *must* be enabled translate_value_oids = 1 # Configures how the symbolic enterprise OID will be displayed for $E. # Set to 1, 2, 3 or 4. See translate_value_oids options 1,2,3 and 4. # Note: net_snmp_perl_enable *must* be enabled translate_enterprise_oid_format = 1 # Configures how the symbolic trap OID will be displayed for $O. # Set to 1, 2, 3 or 4. See translate_value_oids options 1,2,3 and 4. # Note: net_snmp_perl_enable *must* be enabled translate_trap_oid_format = 1 # Configures how the symbolic trap OID will be displayed for $v, $-n, $+n, $-* and $+*. # Set to 1, 2, 3 or 4. See translate_value_oids options 1,2,3 and 4. # Note: net_snmp_perl_enable *must* be enabled translate_varname_oid_format = 1 # Set to 0 to disable converting INTEGER values to enumeration tags as defined in the # MIB files # Set to 1 to enable converting INTEGER values to enumeration tags as defined in the # MIB files # Example: moverDoorState:open instead of moverDoorState:2 # Note: net_snmp_perl_enable *must* be enabled translate_integers = 1 of course it's perl ... so may be a specific case, but it still is supposed to be running as daemon (load MIB files only once when starting and later snmp library only "parses" loaded MIBs), but snmptt's creators added the performance notice, probably based on some tests. This topic requires more deep investigation to be sure. That's all related to my desire to improve zabbix documentation about snmp traps handling That also may be related to zabbix server, which performs a lot of snmp polling, as in snmp OID we are allowed to specify just OID or its translated/readable form and snmp library handles that internally then. |
Comment by dimir [ 2018 Sep 07 ] |
zalex_ua, martins-v, please take a look at this version and let me know if you think this works. zalex_ua 1. in section "Using MIBs in Zabbix" I'd remove everything after sentence "After that, the changes made to MIB files are in effect." 2. I think it's bad idea and suggestion to put mib files to user's folder and define this custom location only for the user's .snmp/snmp.conf file. 3. Don't repeat about required restart, as you already said that. <dimir>
zalex_ua I'm really sorry for the delay to review it. Looks good now. |
Comment by dimir [ 2018 Sep 21 ] |
Closing due to inactivity. |
Comment by dimir [ 2018 Oct 15 ] |
Reopening to change Resolution to "Fixed". |