Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Question] How to load a particular MIB File #1

Closed
aldevar opened this issue Jun 13, 2016 · 4 comments
Closed

[Question] How to load a particular MIB File #1

aldevar opened this issue Jun 13, 2016 · 4 comments

Comments

@aldevar
Copy link

aldevar commented Jun 13, 2016

Hi,

I'm trying to use your script to generate a template from the BGP4-MIB file.
I'm looking for an option to just load this file.

The actual behavior is that the script loads all MIB files present in /usr/share/snmp/mibs/ and generate a 52000 lines template with all MIBS.

Thanks for your work.
Regards,

@cavaliercoder
Copy link
Collaborator

cavaliercoder commented Jun 13, 2016

Thanks for posting your question. mib2zabbix relies on the NetSNMP library to traverse MIB files. NetSNMP requires that MIB files be loaded from the directory you described, or $HOME/.snmp/mibs. Please see the NetSNMP documentation for more information on loading MIB files.

Once the MIB file is loaded into the MIB tree, you can select the OID which you wish to generate a Zabbix template for, by specifying the -o flag when you call mib2zabbix. MIB files typically contain multiple root OIDs, so it's worth inspecting the file to decide which part of the tree you wish to generate a template for. If no OID is given, the entire tree is exported to a template, as you have experienced.

@aldevar
Copy link
Author

aldevar commented Jun 13, 2016

Ok, I see that I misunderstodd the use of mib2zabbix at the first time.
Thank you for your answer

@aldevar aldevar closed this as completed Jun 13, 2016
@cavaliercoder
Copy link
Collaborator

I'm glad you asked, thank you. This may help others too. I need to put together a tutorial soon!

@Gmatoy
Copy link

Gmatoy commented Aug 29, 2017

i need one, i am tottaly lost on this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants