blob: 839f30456db906c6e313d0a405cf1ca1169ba0f0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
How to pass MIB to the Manager
------------------------------
Q. How to make use of my own MIBs at my Manager application?
A. Starting from PySNMP 4.3.x, plain-text (ASN.1) MIBs can be
automatically parsed into PySNMP form by the
`PySMI <http://pysmi.sf.net>`_ tool. PySNMP will call PySMI
automatically, parsed PySNMP MIB will be cached in
$HOME/.pysnmp/mibs/ (default location).
MIB compiler could be configured to search for plain-text
MIBs at multiple local and remote locations. As for remote
MIB repos, you are welcome to use our collection of ASN.1
MIB files at
`http://mibs.snmplabs.com/asn1/ <http://mibs.snmplabs.com/asn1/>`_
as shown below.
.. literalinclude:: /../../examples/hlapi/asyncore/sync/manager/cmdgen/custom-asn1-mib-search-path.py
:start-after: """#
:language: python
:download:`Download</../../examples/hlapi/asyncore/sync/manager/cmdgen/custom-asn1-mib-search-path.py>` script.
Alternatively, you can invoke the
`mibdump.py <http://pysmi.sourceforge.net/user-perspective.html>`_
(shipped with PySMI) by hand and this way compile plain-text MIB
into PySNMP format.
|