Creating master agent and sub agent using snmp4j-agentx
Date : March 29 2020, 07:55 AM
help you fix your problem Adding your own MIB objects (so called ManagedObjects) to your SNMP agent with SNMP4J-AgentX works in the same way as for SNMP4J-Agent. The only exception from this are AgentX shared tables, but these are advanced concepts you generally do not need when you start using AgentX/SNMP. Thus, I recommend reading the SNMP4J-Agent-Instrumentation-Guide.pdf to learn how MIB objects are registered and instrumentated based on your requirements.
|
Using agent name instead of IP as Address in SNMP4J
Date : March 29 2020, 07:55 AM
This might help you You can get the IP address by using DNS resolution, like this answer says: InetAddress address = InetAddress.getByName(switchName);
System.out.println(address.getHostAddress());
|
SNMP4J: Which SNMP4J Jar should be used to write a SNMP agent?
Date : March 29 2020, 07:55 AM
this will help An agent is some kind of server: it mainly replies to requests (it may occasionally also send traps to managers). A manager is a some kind of client: it mainly send requests to agents (it may occasionally also receive traps from managers).
|
DuplicateRegistrationException in SNMP4j Agent
Date : March 29 2020, 07:55 AM
it helps some times For those that follow in my path, the key here is to add a .0 to the end of each of the addresses. This extra zero identifies the variable at that OID and means the addresses don't conflict with one another. Without it, it's just a path to a location without creating a place for the variable itself. registerManagedObject(new MOScalar(new OID("1.3.6.1.4.1.32437.1.5.1.4.2.0"), MOAccessImpl.ACCESS_READ_ONLY, new OctetString("object 1")));
registerManagedObject(new MOScalar(new OID("1.3.6.1.4.1.32437.1.5.1.2.20.0"), MOAccessImpl.ACCESS_READ_ONLY, new OctetString("object 2")));
registerManagedObject(new MOScalar(new OID("1.3.6.1.4.1.32437.1.5.1.2.23.0"), MOAccessImpl.ACCESS_READ_ONLY, new OctetString("object 3")));
registerManagedObject(new MOScalar(new OID("1.3.6.1.4.1.32437.1.5.1.1.21.0"), MOAccessImpl.ACCESS_READ_ONLY, new OctetString("object 4")));
registerManagedObject(new MOScalar(new OID("1.3.6.1.4.1.32437.1.5.1.4.2.1.2.0"), MOAccessImpl.ACCESS_READ_ONLY, new OctetString("object 5")));
|
How to test SNMP4J agent
Date : March 29 2020, 07:55 AM
|