net-snmp

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
hanya.radwan
Posts: 194
Joined: Tue Feb 25, 2014 6:12 am
Location: palestine

net-snmp

Post by hanya.radwan »

hi,

i installed net-snmp on redhat server, and add all MIBs but this server not send trap ?
shall I modify this parameter in snmptt.ini at nagios server "net_snmp_perl_best_guess = 0" to 1?

please I need way to check if remote host send trap or for tracing ?
please what is the best way to deal with traps or help document descrip that in details since I follow up the same steps in the user guide but not traps reach?

thanks,
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: net-snmp

Post by tmcdonald »

Let's check the basics:

Code: Select all

service snmptrapd status
service snmptt status
service crond status
Is the remote server not sending traps or is Nagios not receiving them? Or are you not sure which it is?
Former Nagios employee
hanya.radwan
Posts: 194
Joined: Tue Feb 25, 2014 6:12 am
Location: palestine

Re: net-snmp

Post by hanya.radwan »

i run the command on Nagios server:-

[root@nms ~]# service snmptrapd status
snmptrapd (pid 31337) is running...
You have new mail in /var/spool/mail/root
[root@nms ~]# service snmptt status
snmptt (pid 41311) is running...
[root@nms ~]# service crond status
crond (pid 1854) is running...
regards remote server< I don't know, how can I debug that
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: net-snmp

Post by lmiltchev »

How are you sending traps? Are you using Nagios XI and the SNMP Trap Sender component? Can you explain in details?
Be sure to check out our Knowledgebase for helpful articles and solutions!
hanya.radwan
Posts: 194
Joined: Tue Feb 25, 2014 6:12 am
Location: palestine

Re: net-snmp

Post by hanya.radwan »

it is sending trap
I added rocommunity public 10.102.4.10 .1.3.6.1.2.1.1 to the /etc/snmp/snmpd.conf(remote host server)
snmp Ok:
/check_snmp -H 10.200.21.58 -o .1.3.6.1.2.1.1.3.0 -C public
SNMP OK - Timeticks: (435715) 1:12:37.15 |
also I try to check storage , an error appear:
[root@nms libexec]# ./check_snmp_storage.pl -H 10.200.21.58 -C public -m "^/$" -w 2 -c 4
ERROR: Description/Type table : Requested table is empty or does not exist.
also
[root@nms ~]# snmpwalk -v2c -c public 10.200.21.58 system
No log handling enabled - turning on stderr logging
Cannot find module (IP-MIB): At line 0 in (none)
Cannot find module (IP-FORWARD-MIB): At line 0 in (none)
SNMPv2-MIB::sysDescr.0 = STRING: Linux db1.jawwal.ps 2.6.18-92.el5PAE #1 SMP Tue Apr 29 13:31:02 EDT 2008 i686
SNMPv2-MIB::sysObjectID.0 = OID: NET-SNMP-MIB::netSnmpAgentOIDs.10
DISMAN-EVENT-MIB::sysUpTimeInstance = Timeticks: (349273) 0:58:12.73
SNMPv2-MIB::sysContact.0 = STRING: Root <root@localhost> (configure /etc/snmp/snmp.local.conf)
SNMPv2-MIB::sysName.0 = STRING: db1.jawwal.ps
SNMPv2-MIB::sysLocation.0 = STRING: Unknown (edit /etc/snmp/snmpd.conf)
SNMPv2-MIB::sysORLastChange.0 = Timeticks: (1) 0:00:00.01
SNMPv2-MIB::sysORID.1 = OID: SNMPv2-MIB::snmpMIB
SNMPv2-MIB::sysORID.2 = OID: TCP-MIB::tcpMIB
SNMPv2-MIB::sysORID.3 = OID: RFC1213-MIB::ip
SNMPv2-MIB::sysORID.4 = OID: UDP-MIB::udpMIB
SNMPv2-MIB::sysORID.5 = OID: SNMP-VIEW-BASED-ACM-MIB::vacmBasicGroup
SNMPv2-MIB::sysORID.6 = OID: SNMP-FRAMEWORK-MIB::snmpFrameworkMIBCompliance
SNMPv2-MIB::sysORID.7 = OID: SNMP-MPD-MIB::snmpMPDCompliance
SNMPv2-MIB::sysORID.8 = OID: SNMP-USER-BASED-SM-MIB::usmMIBCompliance
SNMPv2-MIB::sysORDescr.1 = STRING: The MIB module for SNMPv2 entities
SNMPv2-MIB::sysORDescr.2 = STRING: The MIB module for managing TCP implementations
SNMPv2-MIB::sysORDescr.3 = STRING: The MIB module for managing IP and ICMP implementations
SNMPv2-MIB::sysORDescr.4 = STRING: The MIB module for managing UDP implementations
SNMPv2-MIB::sysORDescr.5 = STRING: View-based Access Control Model for SNMP.
SNMPv2-MIB::sysORDescr.6 = STRING: The SNMP Management Architecture MIB.
SNMPv2-MIB::sysORDescr.7 = STRING: The MIB for Message Processing and Dispatching.
SNMPv2-MIB::sysORDescr.8 = STRING: The management information definitions for the SNMP User-based Security Model.
SNMPv2-MIB::sysORUpTime.1 = Timeticks: (0) 0:00:00.00
SNMPv2-MIB::sysORUpTime.2 = Timeticks: (0) 0:00:00.00
SNMPv2-MIB::sysORUpTime.3 = Timeticks: (0) 0:00:00.00
SNMPv2-MIB::sysORUpTime.4 = Timeticks: (0) 0:00:00.00
SNMPv2-MIB::sysORUpTime.5 = Timeticks: (0) 0:00:00.00
SNMPv2-MIB::sysORUpTime.6 = Timeticks: (0) 0:00:00.00
SNMPv2-MIB::sysORUpTime.7 = Timeticks: (0) 0:00:00.00
SNMPv2-MIB::sysORUpTime.8 = Timeticks: (1) 0:00:00.01
SNMPv2-MIB::sysORUpTime.8 = No more variables left in this MIB View (It is past the end of the MIB tree)
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: net-snmp

Post by sreinhardt »

OK you are talking about two totally different but related through the use of snmp, tasks. Are you attempting to run snmpd and have this system accessible for check_snmp checks against it, or do you want it to sent traps to your nagios instance on its own? Your initial comments indicate that you want this system to send to nagios, but your last two posts indicate that you actually just want to be able to use check_snmp against it, we need to clarify what exactly you are attempting to do.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
hanya.radwan
Posts: 194
Joined: Tue Feb 25, 2014 6:12 am
Location: palestine

Re: net-snmp

Post by hanya.radwan »

I want the two options:
1- Nagios check server resources and logs
2-server send traps to Nagios
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: net-snmp

Post by tmcdonald »

Let's take a look at the traps first. Are you getting any entries in your /var/log/snmptt/snmpttunknown.log file relating to the traps? Are there any files in /var/spool/snmptt at all?

Also, can you please identify which IP is for the Nagios server and which is for the remote server to confirm?
Former Nagios employee
hanya.radwan
Posts: 194
Joined: Tue Feb 25, 2014 6:12 am
Location: palestine

Re: net-snmp

Post by hanya.radwan »

no traps in the unknown related to our traps

and there are files in snmptt
[root@nms snmptt]# ls -ltr
total 12
-rw-r--r-- 1 root root 473 Sep 11 12:25 #snmptt-trap-1410427505042897
-rw-r--r-- 1 root root 500 Sep 11 12:25 #snmptt-trap-1410427506110460
-rw-r--r-- 1 root root 476 Sep 11 12:25 #snmptt-trap-1410427506590022

nagios IP:10.102.4.10

remote server IP:10.200.21.58
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: net-snmp

Post by tmcdonald »

Can you post the contents of your /etc/snmp/snmptt.conf file please? Let's also take a look at your snmptt.ini:

Code: Select all

grep "mode =" /etc/snmp/snmptt.ini
Did you follow a particular guide for setting up SNMP traps? If so, please link to it.
Former Nagios employee
Locked