Thanks Nick! strace showed that /etc/hosts was not being opened, but it showed that nsswitch.conf was being opened but did not exist, so I created a nsswitch.conf file with the following line:

hosts:   files dns

Now everything works.

Thank you,

     Russ




>From: Nick Rout <[EMAIL PROTECTED]>
>Reply-To: gentoo-user@lists.gentoo.org
>To: gentoo-user@lists.gentoo.org
>Subject: Re: [gentoo-user] Name Resolution Problem
>Date: Mon, 25 Jul 2005 15:38:12 +1200
>
> > lo is up, verified with ifconfig. I can ping 127.0.0.1, however pinging localhost results in "ping: unknown host localhost". I get the same result with anything else that I add to the hosts file.
> > Thanks,
> >      Russ
>
>I would try strace now to see if /etc/hosts is being opened:
>
>strace -e open ping localhost
>
>(if that generates too much lok at man strace, there is an option to
>save to a file - redirection does not work IIRC.)
>--
>Nick Rout
>
>--
>gentoo-user@gentoo.org mailing list
>
-- gentoo-user@gentoo.org mailing list

Reply via email to