Difference between revisions of "Template:FAQ:Agent 04"
From Net-SNMP Wiki
m (Latest FAQ revision - preparing for 5.5 release) |
(Python is apparently client-side only) |
||
Line 13: | Line 13: | ||
* The agent can pass the request off to another (sub-)agent, which already implements the required MIB. Again, there are several ways of doing this - including AgentX, SMUX and proxied SNMP. See the [[FAQ:Agent_08|next entry but one]] for details. | * The agent can pass the request off to another (sub-)agent, which already implements the required MIB. Again, there are several ways of doing this - including AgentX, SMUX and proxied SNMP. See the [[FAQ:Agent_08|next entry but one]] for details. | ||
− | * You can write code to implement the new MIB objects, and include this within the agent. This is most commonly C (or C++) code, although the agent can also support MIB modules implemented in perl | + | * You can write code to implement the new MIB objects, and include this within the agent. This is most commonly C (or C++) code, although the agent can also support MIB modules implemented in perl.<BR>See the [[FAQ:Coding|next section]] (CODING) for more details. |
Note that there is no visible difference between external commands, | Note that there is no visible difference between external commands, | ||
subagents, and modules implemented within the main agent itself. | subagents, and modules implemented within the main agent itself. | ||
Tools querying the agent will see a single MIB structure. | Tools querying the agent will see a single MIB structure. |
Latest revision as of 11:04, 6 April 2010
Adding a MIB essentially involves writing some code to implement the objects defined in the new MIB. There are three basic approaches that can be used to do this:
- The agent can invoke an external command or shell script to return the necessary information. There are several possible variations on this approach - see the next entry for details.
- The agent can pass the request off to another (sub-)agent, which already implements the required MIB. Again, there are several ways of doing this - including AgentX, SMUX and proxied SNMP. See the next entry but one for details.
- You can write code to implement the new MIB objects, and include this within the agent. This is most commonly C (or C++) code, although the agent can also support MIB modules implemented in perl.
See the next section (CODING) for more details.
Note that there is no visible difference between external commands, subagents, and modules implemented within the main agent itself. Tools querying the agent will see a single MIB structure.