The Troubleshooting tips for SNMPv1/v2c agents are as follows:
Request Timed Out to Agent Host
Reason : This message appears in the Mib Browser on the following conditions :
If the MIB Browser is not configured with the same Community String as the Agent then it will send an authentication trap and will not send any response to the manager.
When the Agent is not running or if the port number and /or host at which the Agent listens, is different from the port number specified in the Mib Browser settings.
If the request sent from the manager is of higher version than it is configured in the agent, then the agent will not send any response to the manager.
When the agent is not able to send the response to the manager within the specified time out value.
Solution : The problem can be resolved by giving the same Community string, host, port number in the Mib Browser Setting as it is configured in the agent. If the problem occurs due to time out value then increase the timeout value.
General Error
The reasons for the error to be thrown in the Master Subagent Architecture is explained below:
Reason :
The "generr" will be thrown by the master agent when the response from the subagent is not received within the specified timeout period.
If the host and the port number entry of the subagent in the proxy table is not the same as it is configured in he subagent.
When the subagent receives a request of higher version from the master agent, then it does not respond to the master agent.
When the Community String in the subagent does not match with the community entry of the subagent in the proxy table.
If the proxyRowStatus column of the particular subagent entry in the Master agent is not active.
Solution : Please ensure whether the Subagent is running in the specified port, community, and host. To resolve the error due to timeout value, use proxyTimeout column in the proxy table of the particular subagent.
No data available in this MIB
Reason : This error occurs when a node is not registered (implemented) in the agent or when there is no entry available in the table and a request is sent.
Solution : Find out the reason for your problem from the above listed reasons and correct it.
End of MIB View
Reason :This message occurs when a GET-BULK is made. It also occurs when GET-NEXT request for v2c request is made to the last variable of the agent.
Solution : If you reduce the max repetitions value, then you will get the proper response from the agent.
No ObjectID specified
Reason : This message occurs when a request is made without selecting an object in the MibTree i.e when the OID is not specified before making a request
Solution : Select a node and send a request.
Invalid OID format
Reason : This message appears when an invalid OID is mentioned for any variable.
Solution : Check the OID of the variables.
No Such Variable Name
Reason : This error message is thrown when doing a GET operation and
The OID is not instrumented by the Agent.
The Read Community specified is not the right one.
If the variable chosen for GET request is write only variable.
When querying a columnar variable with an invalid instance or scalar variable with instance other than 0.
Solution : The error can be avoided by choosing a valid variable as implemented in the agent.
No Host Specified
Reason : If the Host Name is not specified before making any query this error occurs.
Solution : Enter the correct Host name before sending a request to the Agent.
sysDescr in RFC 1213 MIB value being "mySysDescr" and not "mib2AgentSimulator"
Reason : The sysDescr, in SystemInstrument.java file, initializes as protected String sysDecr = "mib2 Agent Simulator"; But it actually gets "mySysDescr" not "mib2 Agent Simulator" when queried. This is because, we have implemented SnmpV2-MIB in the agent which contains systemGroup, sysOrTable and snmp Group. So the generated System group of RFC1213MIB is not registered in the Agent because the System Group of SnmpV2-MIB which we have implemented is registered (the oid for both are same (.1.3.6.1.2.1.1)). So when you do a query to the agent for sysDescr then the agent returns "mySysDescr" default value of the Snmp Group of SnmpV2-MIB which we have implemented.
Solution :If you want to get the value presented in the SystemGroupinstrument.java file, comment the code snippet mentioned below in the Main File i.e RFC1213.java
/* sysORTable = new
com.adventnet.snmp.snmp2.agent.SysORTableRequestHandler((SnmpAgent)this);
sysORTable.addRegistrationListener(hdlr);
SystemGroupInstrument instru = new SystemGroupInstrument();
super.addSystemGroupListener(instru);
*/
If the above mentioned code is commented then Agent Toolkit's System Group and SysOrTable are not registered in the agent. Now compile and start the agent then do a query to the agent then the value will be " mib2 Agent Simulator" which is initialized in the SystemInstrument.java file can be retrieved.
Wrong Value Error
Reason : The error "wrong value" will occur only when the value is not being able to assigned to the variable. Say for example, if the managed object has a range defined from 0 to 10 and you are trying to assign the value 11. In this case the Agent will return this error.
Trap not being received by the Manager
Reason : When a Trap is not received for a specific user you have to check if all the entries specified in the v3 tables are correct. If the trap is not received in the Manager side then check whether the community, port, and host on the Manager side is the same as it is mentioned in the TrapForwarding table.
Bind Exception
Reason: This error is thrown, if another application is running in the port where the agent is already running.
Solution: Stop the application in that specified port and start it in a port after verifying whether the port is in use or not. This can be assured by using netstat -an command to know the ports that are in use. To start the agent in some other port, the option run -p [port number] can also be used where [port number] implies the port which is not used.
Compilation error while compiling the generated code:
Reason: When the code is generated for the list of selected nodes/MIB without adding its imported MIB to the list, then this error is thrown.
Solution: While loading a MIB, the other MIB imported in it also gets loaded. So while adding any MIB to the list, the imported MIB in it should also be added which will avoid this error while code generation.