Resolving Host Issue

Questions about Wi-Fi and other network devices, file sharing, firewalls, connection sharing etc
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
JeremyB
Level 21
Level 21
Posts: 13880
Joined: Fri Feb 21, 2014 8:17 am

Re: Resolving Host Issue

Post by JeremyB »

Dave Box wrote:I will try that but in the meantime I went into Control Center - Network (not network connection) and just for fun changed the DNS that the system sets (127.0.1.1) to the two numbers my ISP provided. I also added 8.8.8.8 and 8.8.8.4 to the search domains field. Now it appears that everything is working. Firefox 31 works (it used to hang on transferring data) and Chrome has not displayed a resolving host message in the last hour. The problem is that even though I click the padlock to the lock position if I reboot the laptop the wireless DNS numbers are wiped out and replaced with 127.0.1.1

In the light of the above information do you still want me to erase the DNS numbers on the router (which I am more than willing to do). Are you familiar enough with Mint 17 to know why the DNS number keeps reseting to 127.0.1.1 on reboot or how to stop that happening which I think might resolve my issue.

Many thanks
Dave
Sounds like you are using LM17 Mate edition as I have only seen a padlock on Mate and that was LM16. Try in terminal

Code: Select all

cat /etc/hosts
after you have changed it from 127.0.1.1 to the ISP DNS

If the /etc/hosts file is different than what I suspect it should be, there is a way to keep the system from changing it

It is likely that it resets to 127.0.1.1 because of an entry in /etc/hosts that is linked with the pc name and this is what my /etc/hosts has

Code: Select all

127.0.0.1	localhost
127.0.1.1	jeremy-Lenovo-G710
213.175.215.218	linuxmint.com
# The following lines are desirable for IPv6 capable hosts
::1     ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
I added the 213.175.215.218 for linuxmint.com after I got some DNS errors
Dave Box

Re: Resolving Host Issue

Post by Dave Box »

This is what I see

david@david-NX860XL ~ $ cat /etc/hosts
127.0.0.1 localhost
127.0.1.1 david-NX860XL

# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
david@david-NX860XL ~ $
JeremyB
Level 21
Level 21
Posts: 13880
Joined: Fri Feb 21, 2014 8:17 am

Re: Resolving Host Issue

Post by JeremyB »

Dave Box wrote:This is what I see

david@david-NX860XL ~ $ cat /etc/hosts
127.0.0.1 localhost
127.0.1.1 david-NX860XL

# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
david@david-NX860XL ~ $
I would try to delete the ISP DNS from the router at this point and see what happens since the DNS from the ISP is already in the system
Dave Box

Re: Resolving Host Issue

Post by Dave Box »

OK so I set the router DNS to 0.0.0.0 and the same for the second address. I then rebooted the router. Then I rebooted the laptop which set the network address back to 127.0.1.1. This got me back to square 1 with Chrome hanging on resolving host and Firefox not even trying. I then set the DNS in networking to the two addresses from my ISP and also set the search DNS to the google numbers and we are up and running.

So it appears that we don't care what is in the router but we do care what is set in network.

If I could just stop the system from resetting to 127.0.1.1 I think I would be good to rock and roll.

Dave
PatH57

Re: Resolving Host Issue

Post by PatH57 »

Hi,

Dave on your router you need the dns from your internet provider (normally this is done automatically at connection through DSL), please provide the model and I will tell you what to look for.

The host files on the unit should look like this
cat /etc/resolv.conf
# 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 192.168.1.1 ----------> my router IP
nameserver 127.0.1.1------------------------------> used for local services and should be there
In 20 years using internet I never had to change it so I'd be surprised you would have to on a normal use.
JeremyB
Level 21
Level 21
Posts: 13880
Joined: Fri Feb 21, 2014 8:17 am

Re: Resolving Host Issue

Post by JeremyB »

Are the extra DNS settings in this location- do not copy and paste the results

Code: Select all

sudo cat "/etc/NetworkManager/system-connections/David Peglar"
Dave Box

Re: Resolving Host Issue

Post by Dave Box »

Gentlemen, once again thank you for your interest in my sad little issue.

Pat, I have a Linksys WRT54G router.

Jeremy, the code you gave me returns exactly what I have entered in Control Center - Network Connections which is my two DNS numbers (from my ISP) and under search DNS the two numbers 8.8.8.8 and 8.8.4.4. That said the only thing that I have done that appears to resolve the issue is to change the setting in Control Center - Network (not connections). When I change the wireless DNS from 127.0.1.1 to the numbers from my ISP everything is fine. As a quadruple check I just rebooted which reset back to 127.0.1.1 and I could not get to this forum because Chrome hangs on resolving host. As soon as I changed back to "my" numbers, well here I am.

I understand that this is something weird, bizarre and unique to my set up as the forum is not abuzz with similar questions so a truly appreciate your time

Dave
PatH57

Re: Resolving Host Issue

Post by PatH57 »

Dave,

if you right click on the network icon and select edit connections, then highlight the wifi connection you are onto and click edit, then IPv4 settings do you have something simillar to this?
Screenshot-Editing MASON_001.png
Dave Box

Re: Resolving Host Issue

Post by Dave Box »

Pat the answer is kind of. We may be using different desktops but if I right click on Network (or Network Connections) I see "Start Network" and "Add to start up Programs" However if I left click on Network Connections and navigate to IPv4 settings I see just what you have except of course my numbers are slightly different and also under Additional search domains I have entered the numbers for Google.

Dave
PatH57

Re: Resolving Host Issue

Post by PatH57 »

Dave,

you should just have automatic DHCP? and additional if you need to?
Dave Box

Re: Resolving Host Issue

Post by Dave Box »

Jeremy,
A few posts ago you said

It is likely that it resets to 127.0.1.1 because of an entry in /etc/hosts that is linked with the pc name and this is what my /etc/hosts has
CODE: SELECT ALL
127.0.0.1 localhost
127.0.1.1 jeremy-Lenovo-G710
213.175.215.218 linuxmint.com
# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters


I added the 213.175.215.218 for linuxmint.com after I got some DNS errors

I think that if I could add my isp provided number(s) as you have done this might cure my DNS errors. Can you walk me through how to do that in baby steps please.

Dave
PatH57

Re: Resolving Host Issue

Post by PatH57 »

Dave,


what you have there is the same as for 90% of the people accessing internet through a router.
Do you have DHCP set to automatic?

Then the problem is a setting in the router not the local machine.

just to make sure try again

Code: Select all

ifconfig
Dave Box

Re: Resolving Host Issue

Post by Dave Box »

Hi Pat

Historically I had a Sony running XP and a Gateway running Windows 7 both through this Linksys router. The only changes I ever made to the router was that my ISP told me to change the two DNS addresses to their server numbers which I did. Everything worked fine for years. The Sony was gradually buckling under the weight of MS bloatware so I decided to convert it to Linux but in the meantime I got given a much nicer (but screwed up ) Gateway which I decided to mess with first and that is the machine we are working with now. The only changes I have made to the router were (as the advice on this thread) to remove the ISP DNS numbers. Now the machine running Windows 7 is working fine and always has.

I have checked the router and it is set to DHCP automatic.

Here are the results of ifconf

david@david-NX860XL ~ $ ifconfig
eth0 Link encap:Ethernet HWaddr 00:e0:b8:9d:0a:c9
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
Interrupt:16 Memory:d4000000-d4020000

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:1417 errors:0 dropped:0 overruns:0 frame:0
TX packets:1417 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:190048 (190.0 KB) TX bytes:190048 (190.0 KB)

wlan0 Link encap:Ethernet HWaddr 00:13:e8:07:3a:97
inet addr:192.168.1.101 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::213:e8ff:fe07:3a97/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:20650 errors:0 dropped:0 overruns:0 frame:0
TX packets:17013 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:19631599 (19.6 MB) TX bytes:3145418 (3.1 MB)

I am the first to admit I know little about this but I do know that with Network DNS set to 127.0.1.1 the internet is unusable but if I remove that number and insert my ISP provided DNS number(s) everything works fine until I reboot when the DNS gets reset to 127.0.1.1.

Please don't think that I am being argumentative but my frustration with resolving the host is sadly souring my experience with Mint 17

Thanks
Dave
PatH57

Re: Resolving Host Issue

Post by PatH57 »

Dave,


you need both but 127.xxxxxx is to your internal PC and DNS is given automatically by your ISP. No need to change anything (and your router is a good one)
So please don't go and touch something if you don't know what it is (you don't need to do this)

now let's investigate the initial problem

Code: Select all

sudo apt-get install python-tk

Code: Select all

wget http://namebench.googlecode.com/files/namebench-1.3.1-source.tgz
this will install the DNS benchmarking tool

Code: Select all

tar xvfvz namebench-1.3.1-source.tgz

Code: Select all

cd namebench-1.3.1

Code: Select all

./namebench.py 
this will run the test
Dave Box

Re: Resolving Host Issue

Post by Dave Box »

Pat,
Is this what you were expecting?

file:///tmp/namebench_2014-07-29_1518.html
PatH57

Re: Resolving Host Issue

Post by PatH57 »

that's the one but you need to attach it to this post (it's in the temp folder of your drive) and you may need to compress it or send me a pm and I will give you my email adress
JeremyB
Level 21
Level 21
Posts: 13880
Joined: Fri Feb 21, 2014 8:17 am

Re: Resolving Host Issue

Post by JeremyB »

Dave Box wrote:Jeremy,
A few posts ago you said

It is likely that it resets to 127.0.1.1 because of an entry in /etc/hosts that is linked with the pc name and this is what my /etc/hosts has
CODE: SELECT ALL
127.0.0.1 localhost
127.0.1.1 jeremy-Lenovo-G710
213.175.215.218 linuxmint.com
# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters


I added the 213.175.215.218 for linuxmint.com after I got some DNS errors

I think that if I could add my isp provided number(s) as you have done this might cure my DNS errors. Can you walk me through how to do that in baby steps please.

Dave
This is not a good fix, it is a temporary work around. Unless PatH finds something, I would delete your current wireless connection and add it back without entering any DNS and see if DHCP does its job like it should.

Are you using satellite connection for internet?
Dave Box

Re: Resolving Host Issue

Post by Dave Box »

Sorry for the delay in replying I had to go out for a while. Pat I ran the test with my DNS numbers added I suspect that I should have done it in the state when it does not work that is to say after a boot with the default 127.0.1.1. I will do it again and send you both results.

Jeremy, it is not a satellite but I am in the deepest depths of South Virginia and my only option is a microwave link to a line of sight tower which gives 2M down and 1M up. It's not the greatest but it works.

Be right back as soon as I run the test again

Thanks guys.
Dave Box

Re: Resolving Host Issue

Post by Dave Box »

namebench_2014-07-29_1838.html.tar.gz
Pat this is the result using the default DNS 127.0.1.1 after rebooting and nothing else. I guess it over wrote the earlier test I made using the ISP DNS numbers. If you need that for comparison let me know

David
PatH57

Re: Resolving Host Issue

Post by PatH57 »

Hi Dave,

that's fine. the weak spot is your microwave link (known to have high latency)

change your wifi connection ipv4 setting as shown here and save. leave automatic DHCP
dave.png
Locked

Return to “Networking”