Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
"Temporary Failure in Name Resolution"
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
George Harrison
n00b
n00b


Joined: 31 Mar 2005
Posts: 57
Location: Pepperland

PostPosted: Wed May 04, 2005 5:55 am    Post subject: "Temporary Failure in Name Resolution" Reply with quote

That's what I see every time I try to emerge something. I am assuming that something is wrong with my /etc/resolv.conf (googled it and figured out that this could possibly be my problem) but I have no idea what I am supposed to put in there. Does this require my IP Address? I ask this because there are a series of numbers that are already there. All I want to do is connect to the internet and it shouldn't be that hard when using DHCP. I am slowly losing my grip on sanity here - what do I put in my /etc/resolv.conf and/or what can I do to get my internet working if it's not the resolv.conf problem? Thanks for the help.
_________________
Athlon 2600+ overclocked to a 3200+, 120GB hd, Soltek board, 1GB of Kingston RAM PC3200, ATI Radeon 9800 XT, cheap case.
Back to top
View user's profile Send private message
anxt
Apprentice
Apprentice


Joined: 25 Feb 2003
Posts: 254
Location: Frozen Tundra, Canada

PostPosted: Wed May 04, 2005 6:40 am    Post subject: Reply with quote

put your dns servers in resolv.conf

can you ping an ip on the internet?

nameserver 64.59.184.13
nameserver 64.59.184.15

the above are nameservers for my isp. they should work but substitute your own. that should be the contents of resolv.conf
Back to top
View user's profile Send private message
George Harrison
n00b
n00b


Joined: 31 Mar 2005
Posts: 57
Location: Pepperland

PostPosted: Thu May 05, 2005 5:08 am    Post subject: Reply with quote

Umm.. lost me already. I am a newbie to Gentoo and more so of a newbie when it comes to networking. DNS? And why do you have two nameserver's in yours? I just copied the /etc/resolv.conf from what was in the Live-CD and put it into my Gentoo file. I'll try copying your file and putting them into my resolv file. Thanks.

Mine looks like this (which was also in my Live-CD)
Code:
nameserver 172.16.0.1
search gateway.2.wire.net

_________________
Athlon 2600+ overclocked to a 3200+, 120GB hd, Soltek board, 1GB of Kingston RAM PC3200, ATI Radeon 9800 XT, cheap case.
Back to top
View user's profile Send private message
Taladar
Guru
Guru


Joined: 09 Oct 2004
Posts: 458
Location: Bielefeld, Germany

PostPosted: Thu May 05, 2005 12:18 pm    Post subject: Reply with quote

Domain Name Servers (DNS) are responsible for translating domain names (www.gentoo.org e.g.) to IP adresses (66.219.59.46 e.g.).
Usually your provider or the administrator of your local network provides you with the IP adresses of those servers. There is usually more than one so when that one is down you have a backup. Your resolv.conf probably doesn't work because you have an IP from a private adress space in there (see RFC 1918 http://www.faqs.org/rfcs/rfc1918.html). You should look on the website of your provider for the correct DNS servers.
Back to top
View user's profile Send private message
atdsm
Tux's lil' helper
Tux's lil' helper


Joined: 15 Jun 2003
Posts: 118
Location: Pennsylvania

PostPosted: Thu May 05, 2005 1:29 pm    Post subject: Reply with quote

Hey. Did you get this fixed yet? I had the same problem this morning, and I found out that it was because I misspelled resolv.conf (note, no "e"). Here's the thread that helped me figure out what was wrong.

Another thing to try is to make sure that your new machine can see the internet from the livecd. To test this, run the command:
Code:
# ping -c 3 www.gentoo.org

when you first start up the liveCD. Here's what you should get (more or less):
Code:
# ping -c 3 www.gentoo.org
PING www.gentoo.org (199.246.73.203) 56(84) bytes of data.
64 bytes from n3203.labattracks.onramp.ca (199.246.73.203): icmp_seq=1 ttl=42 time=59.0 ms
64 bytes from n3203.labattracks.onramp.ca (199.246.73.203): icmp_seq=2 ttl=42 time=53.8 ms
64 bytes from n3203.labattracks.onramp.ca (199.246.73.203): icmp_seq=3 ttl=42 time=55.1 ms

--- www.gentoo.org ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2000ms
rtt min/avg/max/mdev = 53.819/55.993/59.010/2.209 ms


If you can't resolve www.gentoo.org, then your domain name server (DNS) isn't working right in the first place and copying /etc/resolv.conf isn't going to help you at all.

Also, if you are already in the liveCD installation process and have already chrooted and the ping command "isn't found," then what you need to do is press Ctrl+Alt+F2 to get to a new virtual terminal that hasn't chrooted. Try the ping command from there and see if it works. (You can get back to where you were originally by pressing Ctrl+Alt+F1.)

Hope this helps. -Steve
_________________
There are 10 kinds of people: those who know binary and those who don't.
Back to top
View user's profile Send private message
George Harrison
n00b
n00b


Joined: 31 Mar 2005
Posts: 57
Location: Pepperland

PostPosted: Thu May 05, 2005 11:58 pm    Post subject: Reply with quote

I tried to ping yahoo and it said "Unknown Host". My file name is "/etc/resolv.conf", the strangest thing is that I can edit it and save and all but when I reboot my computer and come back to it my resolv will have the original stuff in it rather than my edits. I will try to find the correct DNS but the strange thing is that the command above that I put used to work for me. Of course that's when I was running Gentoo on a 10 gig drive and I wanted a larger drive so I could have more room. I got rid of Gentoo, and then I started a fresh install on my new drive and now it won't work. Here's some different stuff I did with my new install (could this effect the name resolution?):

1. I configured my kernel rather than using genkernel this time

2. I figured out how to actually edit my Portage file resonably well

3. I used the USE flags this time

Yep, that's about it. This is really pissing me off now. I think I am going to sit at my pc and not get up until my internet is fixed. Oh and one more thing that helped me out in my first install was that I forced my DHCP to work I think. I ran this command under root: "dhcpcd eth0" and suddenly it worked. Now this command does nothing for me, neither does "net-setup eth0", I guess I'll just have to fight with my /etc/resolv.conf file for a bit longer.

Thanks for the help.
_________________
Athlon 2600+ overclocked to a 3200+, 120GB hd, Soltek board, 1GB of Kingston RAM PC3200, ATI Radeon 9800 XT, cheap case.
Back to top
View user's profile Send private message
Gherald
Veteran
Veteran


Joined: 23 Aug 2004
Posts: 1399
Location: CLUAConsole

PostPosted: Fri May 06, 2005 12:04 am    Post subject: Reply with quote

George Harrison wrote:
when I reboot my computer and come back to it my resolv will have the original stuff in it rather than my edits

That is because the "dhcpcd" dhcp client is grabbing the settings from your router/modem.

Can you ping your nameserver or any outside IP addresses?
Back to top
View user's profile Send private message
George Harrison
n00b
n00b


Joined: 31 Mar 2005
Posts: 57
Location: Pepperland

PostPosted: Fri May 06, 2005 12:40 am    Post subject: Reply with quote

I just did "ping -c 3 www.yahoo.com" and it told me it was an unknown host. Reading the other thread I think I'm going to add my IP address to the /etc/make.conf file and hopefully that'll work. It sounds like chroot may be a possible probably, too. How do I know when I'm in a chroot? Am I always in? Do I have to to tell it when I want in? I'm confused.. sorry, please try to be patient with me - I suck at Gentoo.

I'll be back in a bit, I should just try to sit in Gentoo and figure this thing out.
_________________
Athlon 2600+ overclocked to a 3200+, 120GB hd, Soltek board, 1GB of Kingston RAM PC3200, ATI Radeon 9800 XT, cheap case.
Back to top
View user's profile Send private message
Gherald
Veteran
Veteran


Joined: 23 Aug 2004
Posts: 1399
Location: CLUAConsole

PostPosted: Fri May 06, 2005 12:42 am    Post subject: Reply with quote

George Harrison wrote:
Reading the other thread I think I'm going to add my IP address to the /etc/make.conf file and hopefully that'll work.

nah
Quote:
It sounds like chroot may be a possible probably, too. How do I know when I'm in a chroot? Am I always in? Do I have to to tell it when I want in? I'm confused.. sorry, please try to be patient with me - I suck at Gentoo.

Each vc (alt+f1,2,3,4,5,6) can be in the chroot independently of the others.

If you "ls /", you're bound to see differences between a chroot (/ is your hard drive) and the livecd environment (/ is the livecd).
Back to top
View user's profile Send private message
George Harrison
n00b
n00b


Joined: 31 Mar 2005
Posts: 57
Location: Pepperland

PostPosted: Fri May 06, 2005 3:00 am    Post subject: Reply with quote

OK.. I'm about to shoot my pc now. I now realize it's defintely my resolv.conf, the DNS Name Resolution is all screwed up. So should my file look something like this?:
Code:
nameserver [insert my IP address here]

and that's all? No "search gateway.2wire.net"? I think what's mainly throwing me off is dhcpcd erasing my resolv file. Could I truly be getting this file correct but dhcpcd is throwing me off? Thanks.
_________________
Athlon 2600+ overclocked to a 3200+, 120GB hd, Soltek board, 1GB of Kingston RAM PC3200, ATI Radeon 9800 XT, cheap case.
Back to top
View user's profile Send private message
Gherald
Veteran
Veteran


Joined: 23 Aug 2004
Posts: 1399
Location: CLUAConsole

PostPosted: Fri May 06, 2005 3:04 am    Post subject: Reply with quote

George Harrison wrote:
OK.. I'm about to shoot my pc now. I now realize it's defintely my resolv.conf, the DNS Name Resolution is all screwed up. So should my file look something like this?:
Code:
nameserver [insert my IP address here]

Your IP address? No! The ip address of your ISP's nameserver. Their DNS server. Their domain name server. Got it?

Quote:
and that's all? No "search gateway.2wire.net"? I think what's mainly throwing me off is dhcpcd erasing my resolv file. Could I truly be getting this file correct but dhcpcd is throwing me off? Thanks.

The search is irrelevant. You need a line with "nameserver <yourisp'snameserver>" and you need to be able to "ping <yourisp'snameserver>".

If you can't ping it, odds are it won't work. And you need to be clear about whether you can ping any outside IP addresses.

For instance, can you ping 64.233.167.147 (google) ?


Last edited by Gherald on Fri May 06, 2005 3:06 am; edited 1 time in total
Back to top
View user's profile Send private message
George Harrison
n00b
n00b


Joined: 31 Mar 2005
Posts: 57
Location: Pepperland

PostPosted: Fri May 06, 2005 3:06 am    Post subject: Reply with quote

Ohh.. I'm retarded. Sorry I didn't mean my IP address.

So should I use something like www.dnsstuff.com to find out my DNS namesever from my ISP?

Well, time for another round. I'll try to ping Google in a vc, too. I know this works, I did it in my first install and everything went just fine. Now it's giving me hell.
_________________
Athlon 2600+ overclocked to a 3200+, 120GB hd, Soltek board, 1GB of Kingston RAM PC3200, ATI Radeon 9800 XT, cheap case.
Back to top
View user's profile Send private message
dfelicia
Apprentice
Apprentice


Joined: 11 May 2005
Posts: 281
Location: Southwestern Connecticut

PostPosted: Thu May 12, 2005 6:24 pm    Post subject: Make sure your default route is correct Reply with quote

As root, type route. Make sure you have a line that starts with default.

e.g.

# route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
x.x.x.x.x * 255.255.255.0 U 0 0 0 eth0
loopback localhost 255.0.0.0 UG 0 0 0 lo
default x.x.x.x 0.0.0.0 UG 0 0 0 eth0

If so, make sure you can ping it. If not, add it:

# route add default gw x.x.x.x

man route for more info.
Back to top
View user's profile Send private message
flash49
Apprentice
Apprentice


Joined: 12 Feb 2005
Posts: 233

PostPosted: Thu May 12, 2005 6:59 pm    Post subject: Reply with quote

I think we should first test if dns is your only Problem:
Could you try if a "ping 66.94.234.13" (one of the yahoo.com adresses) works?

If this works try to delete/move away your resolv.conf and recreate it with:
Code:
echo "nameserver ip_of_ your_nameserver" >/etc/resolv.conf


now try if
Code:
ping yahoo.com
works.


btw. if your resolv.conf gets overwritten by pppd, check if /etc/conf.d/net.ppp0 contains:
Code:
PEERDNS="no"

if your resolv.conf gets overwritten by dhcpcd add "-R" to the dhcpcd_eth0="..." option in /etc/conf.d/net
try also "man dhcpcd"
_________________
Don't bash me.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum