
Hi,
The problem there is that I try to load (and parse) the dependencies. RFC1213 has a dependency (import) with RFC1212 (OBJECT-TYPE FROM RFC-1212), which in turn imports from RFC1158-MIB (DisplayString FROM RFC1158-MIB). So how would I satisfy the import dependencies when not using RFC1158? Or did HP provide a wrong version of RFC1213/RFC1212 which should not have included that depencency?
Attached are the input and output I get with the following command:
smidump --format=xml --keep-going --quiet --level=0 ./rfc1158_MIB-II.mib 2>&1
With kind regards,
Peter Postma
-----Oorspronkelijk bericht----- Van: Juergen Schoenwaelder [mailto:j.schoenwaelder@jacobs-university.de] Verzonden: maandag 16 december 2013 15:44 Aan: Peter Postma CC: libsmi@ibr.cs.tu-bs.de Onderwerp: Re: [libsmi] smidump generating invalid XML output for RFC1158 mib
Hi,
it is difficult to help as long as I am not 100% sure which version you use. In this particular case, RFC1158-MIB has a number of things that are not valid in more recent SMI versions such as SMIv1 and SMIv2. My recommendation would simply to avoid RFC1158-MIB since it has been superseeded by RFC1213-MIB which has been superseeded by other MIBs itself.
/js
On Mon, Dec 16, 2013 at 02:15:31PM +0000, Peter Postma wrote:
Dear list users,
I am trying to dump a MIB to XML using smidump (v0.4.8) but the output provides invalid XML.
The MIB in question is: http://www.snmplink.org/OnLineMIB/Standards/index.html#124 (RFC1158-MIB, "rfc 1158 MIB-II.mib"). Some sources do have syntax errors (like missing comma's) which I corrected in the source file already. The XML output from smidump however is invalid XML. It generates the following XML e.g.:
<table name="ipNetToMediaTable" oid="1.3.6.1.2.1.4.22" status="mandatory"> <description> ... </description> <row name="ipNetToMediaEntry" oid="1.3.6.1.2.1.4.22.1" status="mandatory"> <linkage> </linkage> <description> ... </description> <scalar name="ipNetToMediaIfIndex" oid="1.3.6.1.2.1.4.22.1.1" status="mandatory"> ------------------------
As can be seen in this example, the <row> tag is never closed and neither is the <table> tag. This is not the only occurance though and happends several times in this same file. This means I can not parse the XML output and also means I'm missing data. Is this a known bug? Is there a workaround? Or am I doing something wrong?