<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi!<div><br></div><div>I received this email offlist about the nagiosmib. However, I'm not fluent with SNMP MIBs, so does anyone else have an opinion if this is a safe change to make?</div><div><div><br></div><div>Ton</div><div><br><div>Begin forwarded message:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><font face="Helvetica" size="3" color="#000000" style="font: 12.0px Helvetica; color: #000000"><b>From: </b></font><font face="Helvetica" size="3" style="font: 12.0px Helvetica">Dirk Fieldhouse <<a href="mailto:dirk.fieldhouse@logica.com">dirk.fieldhouse@logica.com</a>></font></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><font class="Apple-style-span" color="#000000"><b><br></b></font></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; min-height: 14px; "><span class="Apple-style-span" style="-webkit-text-stroke-width: -1; ">As identified by Jan-Terje, the author of this message <URL: <a href="http://osdir.com/ml/network.nagios.plugins/2006-09/msg00011.html">http://osdir.com/ml/network.nagios.plugins/2006-09/msg00011.html</a>>, there is an inconsistency in the MIB module NAGIOS-NOTIFY-MIB. Unfortunately smilint, used for the package test, isn't able to detect this problem, because the inconsistent types are both integer types.</span></div></div><div><br>At line 230<br><span class="Apple-tab-span" style="white-space:pre"> </span>nHostNotifyType NotifyType,<br><span class="Apple-tab-span" style="white-space:pre"> </span>nHostNotifyNum Integer32,<br><br>At line 255<br><span class="Apple-tab-span" style="white-space:pre"> </span>nHostNotifyNum OBJECT-TYPE<br><span class="Apple-tab-span" style="white-space:pre"> </span>SYNTAX NotifyType<br><br>Obviously NotifyType, an enumeration, is meant to be the syntax for nHostNotifyType and not for nHostNotifyNum.<br><br>Also from the description for the nHostNotifyNum OBJECT-TYPE ...<br><br><span class="Apple-tab-span" style="white-space:pre"> </span>"This identifies the current notification number for the service or host.<br> <span class="Apple-tab-span" style="white-space:pre"> </span>The notification number increases by one (1) each time a new notification<br> <span class="Apple-tab-span" style="white-space:pre"> </span>is sent out for a host or service (except for acknowledgements). The<br> <span class="Apple-tab-span" style="white-space:pre"> </span>notification number is reset to 0 when the host or service recovers<br> <span class="Apple-tab-span" style="white-space:pre"> </span>(after the recovery notification has gone out). Acknowledgements do not<br> <span class="Apple-tab-span" style="white-space:pre"> </span>cause the notification number to increase."<br><br>... it's clear that Integer32 (signed integer) isn't the right type for nHostNotifyNum, and it should be an unsigned type, Gauge32. Or perhaps Unsigned32, but Gauge32 has the benefit of specifying the behaviour in the vanishly unlikely case of overflowing 32 bits (doesn't wrap).<br><br>For consistency nSvcNotifyNum needs the same change.<br><br>I've attached a Unix diff file corresponding to these changes.<br><br>Am I right in thinking that nothing in Nagios or nagiosplugins actually implements this MIB (say a trap-forwarder) and that it's purely to be used as a convention by event-handlers that send Nagios events as traps?<br><br>Please feel free to redirect this to an appropriate discussion group.<br><br></div></blockquote></div></div></body></html>