nhSnmpTool ERROR: Error when sapwalk2

Document ID : KB000029162
Last Modified Date : 14/02/2018
Show Technical Document Details
Problem:
Running nhSnmpTool command to fetch device MIB may result into following error.
nhSnmpTool -c ABC!+@@!$ xx.xx.xx.xx
Querying
SNMP data. Output is being written here:
/eHealth/tmp/Mibdump-xx.xx.xx.xx.walk
ERROR: Error when sapwalk2:
Error: Recvfrom failed
 
 
Environment:
eHealth version 6.2.2 onward installed on any Windows, UNIX, Linux
 
 
Cause:
Recvfrom failed error is seen when a device does not respond to SNMP request. There can be a multiple factors resulting into the above error. Mentioned under solution section below are some of the most common issues we come across.
 
 
Resolution:
1. SNMP version - Check the SNMP version on the device, and if it is specifically set to use V2 / V1 / V3, then use argument -v2c -v1 or -v3
2. SNMP port - Command uses 161 port by default. If the device is configured to a different port, use -p argument to query on the particular port. For e.g. SystemEDGE agent uses -1691
3. Special Community String - Due to security policy the community strings may contain special characters. Please try following samples if this is the case.
     a. Add double quotes before and after the community string.
          nhSnmpTool -c "ABC!+@@!$" xx.xx.xx.xx
     b. Add -old flag with double quotes.
          nhSnmpTool -c "ABC!+@@!$" xx.xx.xx.xx -old
     c. Do not use quotes at all and just use -old flag.
          nhSnmpTool -c ABC!+@@!$ xx.xx.xx.xx -old