LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 12-12-2017, 06:28 AM   #1
Lucas Rey
LQ Newbie
 
Registered: Jul 2011
Posts: 25

Rep: Reputation: Disabled
RedHat 7 snmpd service failed due to Name or service not known


Dear community, I have a RedHat 7 server installed, but I cannot start the snmpd service due to:
Code:
    server11# systemctl status snmpd
     snmpd.service - Simple Network Management Protocol (SNMP) Daemon.
     Loaded: loaded (/usr/lib/systemd/system/snmpd.service; enabled; vendor preset: disabled)
     Active: failed (Result: exit-code) since Tue 2017-12-12 11:51:13 CET; 25min ago
     Process: 20736 ExecStart=/usr/sbin/snmpd $OPTIONS -f (code=exited, status=1/FAILURE)
     Main PID: 20736 (code=exited, status=1/FAILURE)
    
    Dec 12 11:51:13 oitwi11 systemd[1]: Starting Simple Network Management Protocol (SNMP) Daemon....
    Dec 12 11:51:13 oitwi11 snmpd[20736]: getaddrinfo: serverz1-oam Name or service not known
    Dec 12 11:51:13 oitwi11 snmpd[20736]: getaddrinfo("serverz1-oam", NULL, ...): Name or service not known
    Dec 12 11:51:13 oitwi11 snmpd[20736]: Error opening specified endpoint "serverz1-oam:161"
    Dec 12 11:51:13 oitwi11 snmpd[20736]: Server Exiting with code 1
Well, the error is clear, snmpd service cannot find the serverz1-oam hostname. So, solution could be add it to hosts file. But this is not correct because the real hostname is "server11".
I checked the /etc/snmp/snmpd.conf, but there isn't such config to change.
So, how can I instruct snmp to getaddress to server11 hostname?

Many thanks
Lucas
 
Old 12-12-2017, 07:23 AM   #2
Lucas Rey
LQ Newbie
 
Registered: Jul 2011
Posts: 25

Original Poster
Rep: Reputation: Disabled
DAMN! got it, it was on these config files:
/etc/sysconfig/snmpd
/etc/sysconfig/snmptrapd

Sorry for wasting forum space!

Last edited by Lucas Rey; 12-12-2017 at 07:24 AM.
 
Old 12-13-2017, 03:02 AM   #3
!!!
Member
 
Registered: Jan 2017
Location: Fremont, CA, USA
Distribution: Trying any&ALL on old/minimal
Posts: 997

Rep: Reputation: 382Reputation: 382Reputation: 382Reputation: 382
No problem Just mark Thread 'Solved' (link or ThreadTools at top of page)
so future searchers can find a Solution here.
 
  


Reply


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
redhat 7 systemd failed service on boot bishop2001 Red Hat 1 12-24-2015 05:04 PM
starting snmpd service in088309 Fedora 7 07-01-2012 06:09 AM
snmpd service starting in088309 Linux - Newbie 1 06-14-2012 06:03 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 02:06 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