I'm new to SNMP. I'm looking at snmp4j's demo AgentX subagent TestSubagent.java (http://www.snmp4j.org/agentX/doc/org/snmp4j/agent/agentx/subagent/test/TestSubagent.html) on a linux box, and have been able to get it registered as a subagent with the snmpd daemon, but I'm unclear how to add new OIDs or alter the value of the existing OIDs that are registered (the 1.3.6.1.4.1.4976 tree). Could anyone point me in the right direction?

有帮助吗?

解决方案

You have to register so called ManagedObjects with the DefaultMOServer instance that is used by the sample. There are two major types of ManagedObject: MOScalar and MOTable.

If you have a MIB, you can let AgenPro generate all necessary code. You will only have to put in the instrumentation code then.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top