Closed mumashankar closed 8 years ago
To get the detailed error messages from a MibLoaderException
, please use code similar to this (adapted from the MibbleValidator app):
try {
...
} catch (MibLoaderException e) {
e.getLog().printTo(System.err);
}
This will print the details of all the errors found, and not just the error summary. I guess the documentation could be clearer on this.
Thank you. It helped.
On Wed, Jul 16, 2014 at 3:31 PM, Per Cederberg notifications@github.com wrote:
To get the detailed error messages from a MibLoaderException, please code similar to this (adapted from the MibbleValidator app):
try { ... } catch (MibLoaderException e) { e.getLog().printTo(System.err); }
This will print the details of all the errors found, and not just the error summary. I guess the documentation could be clearer on this.
— Reply to this email directly or view it on GitHub https://github.com/cederberg/mibble/issues/14#issuecomment-49144699.
Best Regards,
Uma Shankar
I am using Mibble 2.9.3 to parse my MIB files (all files are in same folder) using mibble-parser-2.9.3.jar.
I have taken the MIBs from http://www.juniper.net/techpubs/software/junos/junos141/juniper-mibs-14.1R1.10.zip. I have downloaded ENTITY-MIB and added to this package.
The loading code is as follows:
MibLoader mibLdr = new MibLoader(); loadMandatoryMibs(mibLdr); // Here, the mandatory MIBs are loaded -- Successfully Mib m = mibLdr.load(mibFile);
Out of my 229 MIB files, 22 files are failing to load with same exception:
I am receiving below exception for all these files:
Unable to read: mib-jnx-mobile-gateway-sm-ip-pool.txt With exception.getMessage: found 1 MIB loader errors net.percederberg.mibble.MibLoaderException: found 1 MIB loader errors
However, if I load the above MIBs to Mibble UI, the loading is successful. I have tried to see if there is anything wrong with MIB files; but the exception message returned by JAR file is not clear. So, could you please let me know what am I missing that is causing these MIBs fail to load?
Thank you.