Child pages
  • How to run NET-SNMP agent as a subagent of a SNMP4J-AgentX master agent?
Skip to end of metadata
Go to start of metadata

Run SNMP4J-AgentX Master Agent

The following command line starts the SNMP4J-AgentX master agent for testing. The option -X binds the AgentX listen port to the local loop address on port 705

Note: On UNIX systems, you will have to run the agent with root privileges in order to be able to bind ports below 1024.

java -cp snmp4j-agentx-2.0.1.jar;snmp4j-agent-2.0.6.jar;snmp4j-2.1.jar org.snmp4j.agent.agentx.master.test.TestMasterAgent -X tcp: udp: 

Run NET-SNMP Subagent

When the master agent is running, you can start the NET-SNMP subagent:

cd net-snmp-5.5/agent/
./snmpd --X 705 

The option --X lets the NET-SNMP agent run as an AgentX sub-agent that connects to the port 705 on the local host.

Both agents can be stopped and restarted individually, because the subagent will try to reconnect periodically if it loses connection to the master agent.

  • No labels