Template:FAQ:MIBs 07

From Net-SNMP Wiki
Revision as of 22:47, 21 October 2006 by Dts12 (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

The most likely reason is that the line in question contains two (or more) sequences of pairs of dashes. This is often used to try and "comment out" an unwanted line that already contains a comment:

       --   broken ::= { myMIB 1 }   -- This isn't working yet

The assumption here is that a comment continues to the end of the line. Unfortunately, this assumption is not correct. A comment will continue either to the end of the line, or the next occurance of a pair of dashes. Thus in this case, the definition of "broken" is commented out (as intended) but the following text is treated as part of the MIB, and will generate an error.

A similar effect can be obtained when a line of dashes has been used to try and mark separate parts of a MIB file.

Most of the applications have a command-line option (-Pc) which will work around this problem by treating the whole line as a comment. But this is not strictly legal, and the offending MIB file should really be corrected.