Help answer threads with 0 replies.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 12-02-2003, 07:53 AM   #1
Registered: Apr 2003
Location: Netherlands
Distribution: SuSE (before: Gentoo, Slackware)
Posts: 613

Rep: Reputation: 30
postfix can't resolve localhost

I have a strange problem with my just set-up gentoo box. It can't resolve localhost sometimes.. I had this problem with Slackware before, but I'm not sure how to solve it.

Take a look at this:

Dec  2 13:29:35 hal9000 postfix/smtpd[17375]: disconnect from localhost[]
Dec  2 13:29:35 hal9000 postfix/smtp[17381]: 1E58E11A70: to=<diederik@localhost>,
  relay=none, delay=0, status=deferred (SOFT BOUNCE - Name service error for
  name=localhost type=A: Host not found)
and the same happens here:

root@hal9000 ~ # ping localhost
PING localhost ( 56(84) bytes of data.

--- localhost ping statistics ---
1 packets transmitted, 0 received, 100% packet loss, time 0ms

root@hal9000 ~ # host localhost
Host localhost not found: 3(NXDOMAIN)
How does this happen?

localhost is defined in /etc/hosts. Because it's an NAT-ed machine, I've set the domain name to "linux.lan".

Last edited by yapp; 12-02-2003 at 07:54 AM.
Old 12-02-2003, 02:26 PM   #2
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 66
Is the looopback device up? Post the output of:

Are the correct routes in place? Post the output of:
route -n
Old 12-02-2003, 02:48 PM   #3
Senior Member
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660

Rep: Reputation: 69
You need to copy your hosts file to /var/spool/postfix/etc/ and also make sure that localhost is defined correctly in your hosts file.


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
Unable to resolve any hostnames, including localhost calamari Linux - Networking 10 11-02-2005 02:17 PM
can't resolve localhost auji Linux - Networking 16 09-29-2005 03:39 PM
Postfix: iantri Linux - Networking 8 07-27-2004 12:21 PM
HELP: Postfix SMTP only seems to run for localhost lhoff Mandriva 1 02-29-2004 09:34 AM
Postfix - amavisd (?) joseph_1970 Linux - Software 1 02-13-2004 06:42 PM > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 03:36 AM.

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