LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 07-06-2016, 11:43 AM   #1
daithi_dearg
LQ Newbie
 
Registered: Oct 2015
Location: Cork, Ireland
Distribution: Ubuntu 18.04
Posts: 19

Rep: Reputation: Disabled
SNMP: No response from localhost


Hello,

I'm setting up Redhat machines for SNMP Alerts on Whatsup. I have already a CENTOS machine set up on the same alert and I see no issues.

I can do a SNMPwalk with the GUI and I can navigate from Oject ID "1." and see data whereas on the Redhat machines I don't see this. It goes nowhere.

I see this on 2 Redhat boxes.

So now I'm trying to prove is it a local problem or is it with the communication from this Whatsup server to the box.

/etc/snmp/snmpd.conf matches on both boxes.

I was trying running the following but it has problems even on the box that has SNMP working:
Code:
[user@server2 ~]$ sudo snmpwalk -v 1 -c GETS3RV3R1NFO! localhost
Timeout: No Response from localhost
Do I need different syntax?

The ports appear to be open and this matches the working machine:
Code:
[user@server1~]$  sudo netstat -lnp|grep 16
udp        0      0 0.0.0.0:161             0.0.0.0:*                           43818/snmpd
Also can connect to this port:
Code:
[user@server2 ~]$ sudo nc -v -u -w 3 sonarqube 161
Ncat: Version 6.40 ( http://nmap.org/ncat )
Ncat: Connected to 192.168.212.131:161.
Iptables doesn't appear to be an issue:
Code:
[user@server1 ~]$ systemctl status iptables.service
● iptables.service
   Loaded: not-found (Reason: No such file or directory)
   Active: inactive (dead)
Also /etc/selinux/config has SELINUX set to disabled.

If I had syntax to check if this was working locally I'd appreciate it.

Thanks,
David
 
Old 07-06-2016, 11:53 AM   #2
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 24,469

Rep: Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243
Instead of localhost (which probably resolves to 127.0.0.1...the LOOPBACK address), try putting your FQDN or IP address in of the local machine.
 
Old 07-06-2016, 11:58 AM   #3
daithi_dearg
LQ Newbie
 
Registered: Oct 2015
Location: Cork, Ireland
Distribution: Ubuntu 18.04
Posts: 19

Original Poster
Rep: Reputation: Disabled
I'm afraid the FQDN and the IP address get the same result even on the machine that is working for SNMP
 
Old 07-06-2016, 12:13 PM   #4
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 24,469

Rep: Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243
The syntax is correct, and it working on my system here. Are you positive that you have SNMPv1 enabled on your system, and not 2c or 3? What is the result of "service snmpd status"?
 
Old 07-06-2016, 01:02 PM   #5
daithi_dearg
LQ Newbie
 
Registered: Oct 2015
Location: Cork, Ireland
Distribution: Ubuntu 18.04
Posts: 19

Original Poster
Rep: Reputation: Disabled
The machine this is not running on is Redhat 7.2. Are you running this on Redhat?

Even on the machine that SNMP does work on I get the same results for that snmpwalk command. I can run snmpwalk on the whatsup serverand navigate down through the Object IDs.

On the Redhat server that isn't working I have the following in /etc/snmp/snmpd.conf:
Code:
group   notConfigGroup v1           notConfigUser
group   notConfigGroup v2c           notConfigUser
That's correct isn't it?

SNMP service is running:
Code:
[user@server1 ~]$ systemctl status snmpd.service
● snmpd.service - Simple Network Management Protocol (SNMP) Daemon.
   Loaded: loaded (/usr/lib/systemd/system/snmpd.service; disabled; vendor preset: disabled)
   Active: active (running) since Wed 2016-07-06 21:29:19 IST; 3h 6min ago
 Main PID: 43818 (snmpd)
   CGroup: /system.slice/snmpd.service
           └─43818 /usr/sbin/snmpd -LS0-6d -f

Jul 06 21:29:18 server1 systemd[1]: Starting Simple Network Management Protocol (SNMP) Daemon....
Jul 06 21:29:19 server1 snmpd[43818]: NET-SNMP version 5.7.2
Jul 06 21:29:19 server1 systemd[1]: Started Simple Network Management Protocol (SNMP) Daemon..
 
Old 07-07-2016, 08:08 AM   #6
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 24,469

Rep: Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243
Quote:
Originally Posted by daithi_dearg View Post
The machine this is not running on is Redhat 7.2. Are you running this on Redhat?
Even on the machine that SNMP does work on I get the same results for that snmpwalk command. I can run snmpwalk on the whatsup serverand navigate down through the Object IDs. On the Redhat server that isn't working I have the following in /etc/snmp/snmpd.conf:
Code:
group   notConfigGroup v1           notConfigUser
group   notConfigGroup v2c           notConfigUser
That's correct isn't it?
Doesn't look like it. Have you contacted RHEL support, or checked their knowledegbase on how to configure SNMPD??
https://access.redhat.com/documentat...MP-Configuring

It's typically something like
Code:
rocommunity public 127.0.0.1
rwcommunity mysecret 127.0.0.1
...where 'ro' is the read-only (snmpget/snmpwalk), and 'rw' is read/write (suitable for use with snmpset).
Quote:
SNMP service is running:
Code:
[user@server1 ~]$ systemctl status snmpd.service
● snmpd.service - Simple Network Management Protocol (SNMP) Daemon.
   Loaded: loaded (/usr/lib/systemd/system/snmpd.service; disabled; vendor preset: disabled)
   Active: active (running) since Wed 2016-07-06 21:29:19 IST; 3h 6min ago
 Main PID: 43818 (snmpd)
   CGroup: /system.slice/snmpd.service
           └─43818 /usr/sbin/snmpd -LS0-6d -f

Jul 06 21:29:18 server1 systemd[1]: Starting Simple Network Management Protocol (SNMP) Daemon....
Jul 06 21:29:19 server1 snmpd[43818]: NET-SNMP version 5.7.2
Jul 06 21:29:19 server1 systemd[1]: Started Simple Network Management Protocol (SNMP) Daemon..
Do the logs tell you anything??
 
Old 07-07-2016, 09:16 AM   #7
daithi_dearg
LQ Newbie
 
Registered: Oct 2015
Location: Cork, Ireland
Distribution: Ubuntu 18.04
Posts: 19

Original Poster
Rep: Reputation: Disabled
Unfortunately we don't pay for support where we are unfortunately.

According to that guide I have the correct setup but I continue to see the same issues.

I suppose if I don't have a Redhat machine working it's an issue on this OS.

I do have the setting:
Code:
rocommunity password a.b.c.d
I changed the logging in /etc/sysconfig/snmpd to:
Code:
# OPTIONS="-LS0-7d"
from a 6 to a 7 but I'm not seeing increased logging:
Code:
  Active: active (running) since Thu 2016-07-07 20:43:25 IST; 9s ago
 Main PID: 3868 (snmpd)
   Memory: 4.3M
   CGroup: /system.slice/snmpd.service
           └─3868 /usr/sbin/snmpd -LS0-6d -f
I'm not sure what else I can try here.
 
Old 07-07-2016, 09:48 AM   #8
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 24,469

Rep: Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243Reputation: 7243
Quote:
Originally Posted by daithi_dearg View Post
Unfortunately we don't pay for support where we are unfortunately.
Sorry, but if you're using RHEL, you need to PAY FOR IT, no matter where you are. If this is a new system, stop exactly where you are, and load CentOS instead. It's identical to RHEL, but FREE. Without RHEL support, you WILL NOT get updates/patches/bugfixes/security-fixes. The only thing you're going to accomplish without support, is to put a production system is that will very quickly become unstable, insecure, and you will have a MUCH harder time installing any new software in the future. In short, you're only going to give yourself headaches.
Quote:
According to that guide I have the correct setup but I continue to see the same issues. I suppose if I don't have a Redhat machine working it's an issue on this OS. I do have the setting:
Code:
rocommunity password a.b.c.d
I changed the logging in /etc/sysconfig/snmpd to:
Code:
# OPTIONS="-LS0-7d"
from a 6 to a 7 but I'm not seeing increased logging:
Code:
  Active: active (running) since Thu 2016-07-07 20:43:25 IST; 9s ago
 Main PID: 3868 (snmpd)
   Memory: 4.3M
   CGroup: /system.slice/snmpd.service
           └─3868 /usr/sbin/snmpd -LS0-6d -f
I'm not sure what else I can try here.
Back up your existing SNMPD.conf file, and take out everything except for the ro/rw lines, and see what you get.
 
Old 07-07-2016, 10:09 AM   #9
daithi_dearg
LQ Newbie
 
Registered: Oct 2015
Location: Cork, Ireland
Distribution: Ubuntu 18.04
Posts: 19

Original Poster
Rep: Reputation: Disabled
Maybe I didn't explain myself fully.

These Redhat boxes are fully licensed and we have a fully paid Redhat subscription but it just doesn't include anything besides licensing support.

I'll do those steps you suggested and come back to you.
 
  


Reply

Tags
snmp


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
snmpwalk "timeout: No Response from localhost:1161" using net-snmp-5.4.3 khung Linux - Server 5 09-02-2014 04:06 PM
response timeout by snmp agent anubhuti_k Linux - Networking 0 02-20-2005 04:15 AM
NO-response-SNMP ahmed4linux Linux - General 1 11-06-2004 04:01 AM
SNMP Response Error: noSuchName jasonmok Linux - Networking 5 04-08-2004 09:33 AM
snmp :- No response, request timedout Pranesh Linux - Software 0 09-08-2003 09:51 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:44 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration