Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My laptop sees wireless ssid and connects but I get unknown host when trying to ping www.google.co.za, but I get replies when I ping, my other machine connected to the same router can surf the net no problems. I have tried adding nameserver but the laptop keeps loosing the configurations every now and then. Please help!

/etc/resolf.conf after I added nameserver by hand:

# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
share|improve this question
Please provide more information, for example a routing table. Are you using NetworkManager as the tag implies? That might be overwriting your configuration set by hand. – peterph Oct 15 '13 at 10:15
I have a normal ADSL router which is connected to telkom line and getting my IP from service provider. I use cat5 on the rest of the machines and wireless on this specific laptop. My connection is normal IP from ISP and therefore I attached machines to a normal ADSL router, my routing is not complicated. Hope this answers the question Peterph. Could that still be overwritting my config file? – luclanpowr Oct 15 '13 at 10:27
Oh, sorry I misread your question - routing doesn't seem to be the problem indeed. I believe NM could be overwriting your setup. What does your /etc/resolf.conf look like? – peterph Oct 15 '13 at 11:07
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8) # DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN nameserver - this is after I edited my file and added nameserver – luclanpowr Oct 15 '13 at 11:25
Next time please add it into the question (using the edit button. :) As you can see, it even tells you that any changes will be lost. I'm afraid we'll need to know more about what distribution (end version) you are using. – peterph Oct 15 '13 at 11:46

Which OS do you work with? If it's Ubuntu, check out this link: http://askubuntu.com/questions/2321/what-is-the-proper-way-to-change-the-dns-ip

If not, you may still be able to adapt the steps to your system... I think it's not as easy as just editing /etc/resolv.conf on your machine. I think it will be overwritten by Networkmanager. As an alternative, you could possibly disable Networkmanager and work with the "old" ifup and ifdown scripts, but you might use some comfort like automatic WiFi network selection and so on...

share|improve this answer
Thanks TomS, I have done all this steps in GUI and on terminal - but no matter what I do, the nameserver get scratched from /etc/resolv.conf file. Any idea what else to do!!! – luclanpowr Oct 15 '13 at 11:44
Oooopsss! I am running Linux Mint 13 Maya \n \l – luclanpowr Oct 15 '13 at 11:49
how many network connections do you use? One? more? What are the exact settings for the DNS server for each of the network connections? – TomS Oct 15 '13 at 11:52
I've got three more machines on the network and the dns servers on them are I have tried the same IP on this laptop and it just ignores it. My route -n are pointing to the same Ip and – luclanpowr Oct 15 '13 at 11:56
what are the contents of what does cat /etc/resolv.conf say? What does nm-tool | grep -i dns show? – TomS Oct 15 '13 at 12:05

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.