Page 1 of 1

NAGIOS SNMP Monitoring

Posted: Wed Nov 21, 2012 4:09 am
by wipro-cloud-services
Team,
We are trying to configure monitoring using SNMP service. We have executed the below commands in client machine but error message states "ERROR: Description/Type table : Requested table is empty or does not exist." Please let us know what could be the problem and help us in resolving.
Commands:
cd /etc/snmp
mv snmpd.conf snmpd.conf.bak
vi snmpd.conf
rocommunity public 134.163.34.0/23
rocommunity public 10.194.25.0/26
/etc/init.d snmpd restart
iptables -I INPUT -p udp --destination-port 161 -j ACCEPT
/etc/init.d/iptables save
chkconfig snmpd on
/etc/init.d/snmpd start

Warm regards,
Sumanth Kumar

Re: NAGIOS SNMP Monitoring

Posted: Wed Nov 21, 2012 11:57 am
by scottwilkerson
What is the command you are using that gets back "ERROR: Description/Type table : Requested table is empty or does not exist." Maybe we have an invalid OID?

Can you run
./check_snmp -H <IP_ADDRESS> -C public -o sysUpTime.0

Re: NAGIOS SNMP Monitoring

Posted: Wed Nov 21, 2012 11:32 pm
by wipro-cloud-services
We are receiving error after configuring the client machine in Nagios XI Web console.
Command Output:
# ./check_snmp -H 10.194.130.156 -C public -o sysUpTime.0
SNMP problem - No data received from host
CMD: /usr/bin/snmpget -t 1 -r 5 -m ALL -v 1 [authpriv] 10.194.130.156:161 sysUpTime.0

This seems to be a connection problem. Can you please confirm.

We are not using SNMP community string as "PUBLIC", we have given as "testacc". Should we change the command as "rocommunity testacc <IP-ADDRESS>"

Re: NAGIOS SNMP Monitoring

Posted: Wed Nov 21, 2012 11:45 pm
by wipro-cloud-services
Also, executed below command and connection was successful..

[root@ip-10-194-150-8 libexec]# ./check_snmp -H 10.194.130.156 -C testacc -o sysUpTime.0
SNMP OK - Timeticks: (14862727) 1 day, 17:17:07.27 |

Instead of Public, i have used testacc.

Re: NAGIOS SNMP Monitoring

Posted: Thu Nov 22, 2012 5:48 am
by wipro-cloud-services
Is there any way to enter the OID in config file. copied below are config file entries...

###############################################################################
#
# Host configuration file
#
# Created by: Nagios QL Version 3.0.3
# Date: 2012-11-22 05:39:12
# Version: Nagios 3.x config file
#
# --- DO NOT EDIT THIS FILE BY HAND ---
# Nagios QL will overwite all manual settings during the next update
#
###############################################################################

define host {
host_name zew-v-0ac2829c.vpc2-eu.aws.shell-cloud.com
use xiwizard_linuxsnmp_host
address 10.194.130.156
parents localhost
max_check_attempts 5
check_interval 5
retry_interval 1
check_period xi_timeperiod_24x7
notification_interval 60
notification_period xi_timeperiod_24x7
icon_image snmppenguin.png
statusmap_image snmppenguin.png
_xiwizard linuxsnmp
register 1
}

###############################################################################
#
# Host configuration file
#
# END OF FILE
#
###############################################################################

Re: NAGIOS SNMP Monitoring

Posted: Fri Nov 23, 2012 8:00 am
by scottwilkerson
wipro-cloud-services wrote:Also, executed below command and connection was successful..

[root@ip-10-194-150-8 libexec]# ./check_snmp -H 10.194.130.156 -C testacc -o sysUpTime.0
SNMP OK - Timeticks: (14862727) 1 day, 17:17:07.27 |

Instead of Public, i have used testacc.
Ok, this looks like it worked...

I would try again replacing sysUpTime.0 with the OID you want to check.
wipro-cloud-services wrote:Is there any way to enter the OID in config file. copied below are config file entries...
This is just the host check, normally you would make the changed in the CCM for the particular service and the OID will go in there

Re: NAGIOS SNMP Monitoring

Posted: Sun Nov 25, 2012 11:54 pm
by wipro-cloud-services
Any updates, Still facing same error......

Re: NAGIOS SNMP Monitoring

Posted: Mon Nov 26, 2012 1:34 pm
by scottwilkerson
did you
scottwilkerson wrote:try again replacing sysUpTime.0 with the OID you want to check.
??

Re: NAGIOS SNMP Monitoring

Posted: Fri Nov 30, 2012 2:08 am
by wipro-cloud-services
[root@ip-10-194-150-8 libexec]# ./check_snmp -H 10.194.130.156 -C testacc -o NET-SNMP-MIB::netSnmpAgentOIDs.10
SNMP problem - No data received from host
CMD: /usr/bin/snmpget -t 1 -r 5 -m ALL -v 1 [authpriv] 10.194.130.156:161 NET-SNMP-MIB::netSnmpAgentOIDs.10
[root@ip-10-194-150-8 libexec]#

replaced with OID, still same error.

Re: NAGIOS SNMP Monitoring

Posted: Fri Nov 30, 2012 8:45 am
by scottwilkerson
This is the response you will get if the OID is not found on the system you are querying

You might want to walk the tree grepping for the value

Code: Select all

/usr/bin/snmpwalk -t 1 -r 5 -m ALL -v 1 -c testacc 10.194.130.156 |grep netSnmpAgentOIDs