You are not logged in.

#1 2007-07-16 22:43:22

OssiR
Member
From: Finland
Registered: 2006-12-28
Posts: 39
Website

My Internet crawls...

I have this strange problem with internet connection.

Example.
When ever i click some link in Firefox. Firefox's indicator starts to roll. Indicator rolls something like 10 seconds and suddenly after that it loads the site. Same thing is with every other program that uses internet connection.

Before this i had same kind of lag before every program startup.
I solved that by adding my hostname to /etc/hosts before localhost.

127.0.0.1       myhost  localhost.localdomain   localhost

Any ideas how i could solve the internet problem?

Offline

#2 2007-07-16 23:40:43

ralvez
Member
From: Canada
Registered: 2005-12-06
Posts: 1,718
Website

Re: My Internet crawls...

Is this a direct connection or are you going through a router?
Have you set up your /etc/resolv.conf with the correct DNS server that your IP gave you?

Offline

#3 2007-07-16 23:59:02

OssiR
Member
From: Finland
Registered: 2006-12-28
Posts: 39
Website

Re: My Internet crawls...

ralvez wrote:

Is this a direct connection or are you going through a router?

Yes, it goes through my linux router box.

ralvez wrote:

Have you set up your /etc/resolv.conf with the correct DNS server that your IP gave you?

My resolv.conf is generated by dhcpcd.

Offline

#4 2007-07-17 00:35:16

lucke
Member
From: Poland
Registered: 2004-11-30
Posts: 4,018

Re: My Internet crawls...

Offline

#5 2007-07-17 01:01:01

OssiR
Member
From: Finland
Registered: 2006-12-28
Posts: 39
Website

Re: My Internet crawls...

lucke wrote:

It's not just firefox. Every program that uses internet does the same "lag" before they start to suddenly operate as should be.
Connection works just fine when i boot up to windows on same machine.

Offline

#6 2007-07-17 01:10:30

cactus
Taco Eater
From: t͈̫̹ͨa͖͕͎̱͈ͨ͆ć̥̖̝o̫̫̼s͈̭̱̞͍̃!̰
Registered: 2004-05-25
Posts: 4,622
Website

Re: My Internet crawls...

You could try disabling ipv6 globallly...
http://wiki.archlinux.org/index.php/IPv … the_Module


"Be conservative in what you send; be liberal in what you accept." -- Postel's Law
"tacos" -- Cactus' Law
"t̥͍͎̪̪͗a̴̻̩͈͚ͨc̠o̩̙͈ͫͅs͙͎̙͊ ͔͇̫̜t͎̳̀a̜̞̗ͩc̗͍͚o̲̯̿s̖̣̤̙͌ ̖̜̈ț̰̫͓ạ̪͖̳c̲͎͕̰̯̃̈o͉ͅs̪ͪ ̜̻̖̜͕" -- -̖͚̫̙̓-̺̠͇ͤ̃ ̜̪̜ͯZ͔̗̭̞ͪA̝͈̙͖̩L͉̠̺͓G̙̞̦͖O̳̗͍

Offline

#7 2007-07-17 01:20:29

OssiR
Member
From: Finland
Registered: 2006-12-28
Posts: 39
Website

Re: My Internet crawls...

cactus wrote:

You could try disabling ipv6 globallly...
http://wiki.archlinux.org/index.php/IPv … the_Module

Sorry, i didn't mentioned on last post. I already tried that also.

Offline

#8 2007-07-17 10:12:13

Mikko777
Member
From: Suomi, Finland
Registered: 2006-10-30
Posts: 837

Re: My Internet crawls...

Well like ppl have said so  far usually the slow internet / apps is caused by:

1: no loopback in rc.conf
2: no hostname set
3: having ipv6 enabled and not a ipv6 compatible router
4: crappy dns server?

try pinging do they "lag" wink try connecting to a site with the sites ip addres instead of url.
If those are fast change dns server / address.

Thats all I can think of.

Offline

#9 2007-07-17 11:32:54

OssiR
Member
From: Finland
Registered: 2006-12-28
Posts: 39
Website

Re: My Internet crawls...

Ok, i noticed strange thing as i took closer look to /etc/resolv.conf

These nameservers which are shared by dhcp doesn't even exist.
Does Windows get nameservers somehow different way, because in Windows i get correct nameservers from my other linux box?

Offline

#10 2007-07-17 12:42:30

Misfit138
Misfit Emeritus
From: USA
Registered: 2006-11-27
Posts: 4,189

Re: My Internet crawls...

If the nameservers don't exist, specify your own. smile
Actually, you can just use the ip address of your Linux server gateway as your nameserver. I use a DSL router that gives out 192 addresses, so in my case I can just use
nameserver 192.168.1.1





here are some that I have in my own.

nameserver 208.67.222.222
nameserver 208.67.220.220
nameserver 4.2.2.1
nameserver 4.2.2.2
nameserver 4.2.2.3
nameserver 4.2.2.4
nameserver 4.2.2.5
nameserver 4.2.2.6


Hope this helps.

Last edited by Misfit138 (2007-07-17 12:48:46)

Offline

#11 2007-07-17 12:50:50

OssiR
Member
From: Finland
Registered: 2006-12-28
Posts: 39
Website

Re: My Internet crawls...

Misfit138 wrote:

If the nameservers don't exist, specify your own. smile
here are some that I have in my own.

I tried to add my ISP's nameservers, but the dhcp generated removes those lines.
I just don't get it why my Windows installation gets those nameservers just fine from my routerlinux and Linux on this machine won't.

Offline

#12 2007-07-17 13:28:52

ralvez
Member
From: Canada
Registered: 2005-12-06
Posts: 1,718
Website

Re: My Internet crawls...

You can overwrite the DHCP server. I do that with one of the systems I use.
This is what to do:
1. create a file called /etc/myresolv.conf (just copy your original resolv.conf and edit it)
2. Add the DNS servers that work on that file
3. Edit /etc/rc.local
4. Type the following :
#overwrite DHCP resolv.conf
cp /etc/myresolv.conf /etc/resolv.conf

Now you will have the DNS servers you defined.

Hope this helps.

R

Offline

#13 2007-07-18 18:16:47

evol
Member
From: Ireland
Registered: 2007-06-27
Posts: 53
Website

Re: My Internet crawls...

I suffered the same problem and solved it by creating a file called dhclient.conf in /etc

It looks like this:

prepend domain-name-servers  208.67.222.222, 208.67.220.220;
request subnet-mask, broadcast-address, time-offset, routers, domain-name, domain-name-servers, host-name;
require subnet-mask, domain-name-servers;
timeout 60;
retry 60;
reboot 10;
select-timeout 5;
initial-interval 2;

The DNS servers listed above are from OpenDNS


-//------------------/------>

Offline

#14 2007-07-20 09:46:49

vacant
Member
From: downstairs
Registered: 2004-11-05
Posts: 816

Re: My Internet crawls...

evol wrote:

The DNS servers listed above are from OpenDNS

OpenDNS can do a lot more for those who are interested. Like correcting typos in urls, shortcuts, anti-phishing. For our Cybercafé, I've set up adult site blocking (already have dansguardian on our server so belt and braces). The only hoop I had to jump through was to compile the modified inadyn source from OpenDNS rather than Arch AUR.

Offline

#15 2007-07-20 10:27:13

Ramses de Norre
Member
From: Leuven - Belgium
Registered: 2007-03-27
Posts: 1,289

Re: My Internet crawls...

Using my router's IP for DNS never really worked out here... I just gave in my ISP's DNS servers directly and that works like a charm.

Offline

#16 2007-07-20 11:21:51

ralvez
Member
From: Canada
Registered: 2005-12-06
Posts: 1,718
Website

Re: My Internet crawls...

Actually, the way it is done is:
1. use your ISP DNS addresses in your router and
2. use your router's IP as the DNS for the network.

That way you do not have to put the DNS addresses too many times if you have several computers in your network and you have a single point of management for changes (although, they rarely change).

R.

Offline

#17 2007-07-20 16:04:53

Misfit138
Misfit Emeritus
From: USA
Registered: 2006-11-27
Posts: 4,189

Re: My Internet crawls...

ralvez wrote:

Actually, the way it is done is:
1. use your ISP DNS addresses in your router and
2. use your router's IP as the DNS for the network.

That way you do not have to put the DNS addresses too many times if you have several computers in your network and you have a single point of management for changes (although, they rarely change).

R.

This is the best solution, I agree. I had this working rather well with my old cable modem + router setup, however, my new connection is a DSL modem-router all-in-one, with no effective way of specifying DNS.

Offline

#18 2007-07-20 20:27:50

somairotevoli
Member
Registered: 2006-05-23
Posts: 335

Re: My Internet crawls...

Once you get this sorted, you may also want to look into setting up a local dns cache.

There are different ways to go about this. Just do a google search for more info. Here's one way to go about it.



lucke wrote:

You might also set up local dns caching, which speeds up surfing quite a bit - install dnsmasq, mv /etc/resolv.conf /etc/resolv.conf.dnsmasq, set resolv-file to /etc/resolv.conf.dnsmasq in /etc/dnsmasq.conf, add nameserver 127.0.0.1 to /etc/resolv.conf, execute /etc/rc.d/dnsmasq start, use dig from dnsutils package to confirm that it caches dns entries. Remember to add dnsmasq to /etc/rc.conf.

Last edited by somairotevoli (2007-07-20 20:29:41)

Offline

#19 2007-07-23 02:22:13

Cogar
Member
Registered: 2007-07-22
Posts: 43

Re: My Internet crawls...

ralvez wrote:

You can overwrite the DHCP server. I do that with one of the systems I use.
This is what to do:
1. create a file called /etc/myresolv.conf (just copy your original resolv.conf and edit it)
2. Add the DNS servers that work on that file
3. Edit /etc/rc.local
4. Type the following :
#overwrite DHCP resolv.conf
cp /etc/myresolv.conf /etc/resolv.conf

Now you will have the DNS servers you defined.

Hope this helps.

R

Very good solution. Like some others, my router (Actiontec GT701-WG) would not properly report DNS addresses, and another method was necessary.

Offline

#20 2007-07-25 04:18:19

Beavis
Member
From: UK
Registered: 2005-01-01
Posts: 71

Re: My Internet crawls...

Alternatively you could modify the DHCPCD_ARGS line in /etc/conf.d/dhcpcd by adding a -R option. This should then prevent your resolv.conf file from being overwritten by dhcp.  man dhcpcd can give you more details.

Offline

#21 2007-07-25 16:21:14

bored2k
Member
Registered: 2006-01-14
Posts: 39

Re: My Internet crawls...

My Internet also lags quite a bit.

Here's my /etc/hosts:

127.0.0.1        dudley.localdomain    dudley

Here's my /etc/resolv.conf:

nameserver 192.168.1.2
nameserver 196.3.81.5
nameserver 196.3.81.32
nameserver 208.67.222.222
nameserver 208.67.220.220
nameserver 4.2.2.1
nameserver 4.2.2.2
nameserver 4.2.2.3
nameserver 4.2.2.4
nameserver 4.2.2.5
nameserver 4.2.2.6

(192.168.1.2 is my gateway address)

Do I have something wrong here?
Btw, I've heard having the following type of hosts file is better:

127.0.0.1        dudley.localdomain    dudley localhost

Any truth in this?


Btw, I have Static IPs through a router.

Last edited by bored2k (2007-07-25 16:23:54)

Offline

#22 2007-07-25 16:50:26

Misfit138
Misfit Emeritus
From: USA
Registered: 2006-11-27
Posts: 4,189

Re: My Internet crawls...

Couple things you might want to tweak.
I believe it is best for compatibility purposes if your /etc/hosts is setup as such, with static ip

127.0.0.1        dudley.localdomain.org   localhost.localdomain   localhost dudley
192.168.1.x                        dudley.localdomain.org    dudley

Last edited by Misfit138 (2007-07-25 23:24:42)

Offline

#23 2007-07-25 17:02:29

bored2k
Member
Registered: 2006-01-14
Posts: 39

Re: My Internet crawls...

Misfit138 wrote:

Couple things you might want to tweak.
I believe it is best for compatibility purposes if your resolv.conf is setup as such, with static ip

127.0.0.1        dudley.localdomain.org   localhost.localdomain   localhost dudley
192.168.1.x                        dudley.localdomain.org    dudley

Thanks, I'll see how that works out (with the "x" as my actual IP number).

Offline

#24 2007-07-26 01:39:31

Misfit138
Misfit Emeritus
From: USA
Registered: 2006-11-27
Posts: 4,189

Re: My Internet crawls...

BTW, that's /etc/hosts, NOT /etc/resolv.conf. (Edited my post, sorry bout that.)
Bored2k, you may simply want to try and specify DNS in your router, and then use your router's gateway ip as your nameserver in /etc/resolv.conf on your Arch box.
As was mentioned by ralvez, this is really the most expedient method, if you can get away with it.
So
1. Go into router to change/specify DNS (I like openDNS- 208.67.222.222 and 208.67.220.220)
2. Change /etc/resolv.conf to nameserver <router ip>
Try that and post back smile
Note: This is for static ip. As Beavis mentioned, if you are using DHCP, this file will be dynamically created and destroyed, so edit DHCPCD_ARGS line in /etc/conf.d/dhcpcd by adding a -R option like this: DHCPCD_ARGS="-R -t 30 -h $HOSTNAME"

Offline

#25 2007-07-26 10:27:39

Obi-Lan
Member
From: Finland
Registered: 2007-05-23
Posts: 179

Re: My Internet crawls...

Wouldn't it be just simpler configure DHCP server with correct ips? (unless you got dhcp coming from isp..)

Offline

Board footer

Powered by FluxBB