Monitoring with SNMP

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: Monitoring with SNMP

Post by tgriep »

The filtered state output from the nmap command is pointing to a firewall / device that is blocking SNMP information to be polled by the Nagios server.
Can you verify that the firewall is allowing inbound connections to UDP port 161 and that there is not a device between the Nagios server and the host that could be blocking as well?
The nmap command should show an open state for it's output if the port is open.
Be sure to check out our Knowledgebase for helpful articles and solutions!
ednaldojta
Posts: 103
Joined: Tue Apr 07, 2015 7:52 am

Re: Monitoring with SNMP

Post by ednaldojta »

Iptables is inactive.
afflows imagem.
You do not have the required permissions to view the files attached to this post.
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: Monitoring with SNMP

Post by tgriep »

Edit the /etc/snmp/snmpd.conf file and replace it with the following.

Code: Select all

com2sec notConfigUser  default       public
group   notConfigGroup v1           notConfigUser
group   notConfigGroup v2c           notConfigUser
view    systemview    included   .1.3.6.1.2.1.1
view    systemview      included  .1.3.6.1.2.1.25
view    systemview          included        interfaces.ifTable.ifEntry.ifAdminStatus
view    systemview          included        .1 80
access  notConfigGroup ""      any       noauth    exact  systemview none none
syslocation Unknown (edit /etc/snmp/snmpd.conf)
syscontact Root <root@localhost> (configure /etc/snmp/snmp.local.conf)
dontLogTCPWrappersConnects yes
Then restart the SNMP daemon by running
service snmpd restart

The above settings allow all hosts to access the SNMP Daemon on that host using version 2c and the community name of public.
Try that out and let us know if this fixes it for you.
Be sure to check out our Knowledgebase for helpful articles and solutions!
ednaldojta
Posts: 103
Joined: Tue Apr 07, 2015 7:52 am

Re: Monitoring with SNMP

Post by ednaldojta »

Friends got communication, however I think there is still something for me.
When set up to monitor via snmp for linux, it happens the following message.
You do not have the required permissions to view the files attached to this post.
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: Monitoring with SNMP

Post by tgriep »

Can you login to the Nagios server, run the following and post the output?

Code: Select all

/usr/local/nagios/libexec/check_snmp_storage_wizard.pl -H 10.10.60.52 -C public --v2c -m Physical -w 90 -c 99 -f
Can you run this command and post the /tmp/walk.txt file so we can review it?

Code: Select all

snmpwalk 10.10.60.52 -c public -v 2c >/tmp/walk.txt
If you changed the community string to something other that public, update the above commands.
Be sure to check out our Knowledgebase for helpful articles and solutions!
ednaldojta
Posts: 103
Joined: Tue Apr 07, 2015 7:52 am

Re: Monitoring with SNMP

Post by ednaldojta »

afflowers
You do not have the required permissions to view the files attached to this post.
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: Monitoring with SNMP

Post by tgriep »

The output of the snmpwalk shows that the remote system cannot be polled using SNMP so there is still something wrong with it.
Did you update the snmpd.conf file on that server with what I posted and restart the SNMP Daemon?
Is the IP address remote system you are trying to monitor 10.10.60.52?
What is the Operating System running on the remote server and it's version number?
Be sure to check out our Knowledgebase for helpful articles and solutions!
ednaldojta
Posts: 103
Joined: Tue Apr 07, 2015 7:52 am

Re: Monitoring with SNMP

Post by ednaldojta »

Yes, I updated! Follows the two arquivos.conf of the two machines.
OS versions of the machines are.

Nagios Server - CentOS - 6.7 (Final)
Remote Machine - CentOS 07/02/1511 (Core)

Iptables the two are disabled.
You do not have the required permissions to view the files attached to this post.
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: Monitoring with SNMP

Post by tgriep »

If the nmap command below still shows that the UDP port 161 is filtered, then something is blocking the connection to the remote system. Run this from the Nagios XI server.

Code: Select all

nmap 10.10.60.52 -sU -p 161
If the port is open, the output of the nmap should look like this showing that the port is open.

Code: Select all

Nmap scan report for 192.168.112.130
Host is up (0.0055s latency).
PORT    STATE SERVICE
161/udp open  snmp
The only thing I can think of is that there is something between the 2 systems blocking the SNMP Polls.
Be sure to check out our Knowledgebase for helpful articles and solutions!
ednaldojta
Posts: 103
Joined: Tue Apr 07, 2015 7:52 am

Re: Monitoring with SNMP

Post by ednaldojta »

Follows as requested. However iptables is Down.
Both in Nagios as the remote machine.
You do not have the required permissions to view the files attached to this post.
Locked