NetXMS Support Forum

English Support => General Support => Topic started by: testos on February 18, 2011, 02:59:54 PM

Title: nxmibc error compilation
Post by: testos on February 18, 2011, 02:59:54 PM
Hi,

nxmibc tool can not to compile the mib declaration following :

       MODULE MANDATORY-GROUPS {zoneConfigurationGroup,
                                 zoneStatisticsGroup,
                                 zoneNotificationControlGroup,
                                 zoneNotificationGroup}

It display this complaint:
./CISCO-ZS-MIB.txt: ERROR 003: Parser error - syntax error, unexpected LEFT_BRACE_SYM, expecting ASSIGNMENT_SYM or MODULE_SYM in line 3387

You can try to compile attached file.


Best regards.
Title: Re: nxmibc error compilation
Post by: testos on February 18, 2011, 03:48:24 PM
By the by, I'm trying to compile all these CISCO mibs, downloaded from official
ftp://ftp.cisco.com/pub/mibs/v2/ (http://ftp://ftp.cisco.com/pub/mibs/v2/) and I am getting several others compilation errors.
I can not attach large prepared .rar
Title: Re: nxmibc error compilation
Post by: Victor Kirhenshtein on February 19, 2011, 06:00:31 PM
Hi!

I run MIB compiler against Cisco MIBs from location you provided. Some of the MIBs really contains errors, but most compiler errors are bugs in nxmibc. I have fixed them, next release will contain improved MIB compiler. If you need, I can post a patch for MIB compiler here.

Best regards,
Victor
Title: Re: nxmibc error compilation
Post by: testos on February 19, 2011, 07:56:33 PM
Hi there,

Okay, I would  like you please post here a patch for a Linux server   :).  One thing I would like ask you about nxmibc: compilations are cumulatives (overwriting previous if it was already) or each new compilation remove all above?

Thank you very much for your help.
Title: Re: nxmibc error compilation
Post by: Victor Kirhenshtein on February 22, 2011, 03:27:38 AM
Attached. Patch file contains modified parser.l and parser.y from src/nxmibc directory, and in case you don't have flex and bison resulting C files.

Compilation is not cumulative - each time nxmibc reads all presented source MIBs and generate compiled file, erasing previously created one, if any.

Best regards,
Victor
Title: Re: nxmibc error compilation
Post by: testos on February 22, 2011, 12:25:49 PM
Thank you very much.

I get several errors when I do this gcc compilation:
gcc -Wall -o nxmibc -I../../include lex.yy.c y.tab.c

What is the proper way for gcc compilation?
Title: Re: nxmibc error compilation
Post by: Victor Kirhenshtein on February 22, 2011, 01:03:36 PM
You should put all files from the archive into src/nxmibc directory (replacing existing files) and run command make (assuming you still have configured source tree). If you remove sources you have built NetXMS from, you need to unpack them again, replace files, and then run ./configure and make as usual. If build will be successful, run make install to put resulting binary to appropriate place.

Best regards,
Victor
Title: Re: nxmibc error compilation
Post by: testos on February 23, 2011, 12:04:09 PM

Now all work fine.
Great, fast and perfect reply (as always), your support pokes out in the eyes from commercial products... ;)

I will sent .rar mibs for Fortinet firewalls and HP Procurve switches.

Thx