Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Another slow DNS issue
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
drawsmcgraw
Tux's lil' helper
Tux's lil' helper


Joined: 11 Oct 2004
Posts: 126
Location: Starkville, Mississippi USA

PostPosted: Sun Aug 21, 2005 2:36 pm    Post subject: Another slow DNS issue Reply with quote

Forgive me for contributing another one of these posts, but I honestly have not found solutions in the forums thus far...

I have the usual, I use Firefox (1.0.6) and whenever I punch a URL into the browser, I sit for about 10-60 seconds staring at the little "looking up site.domain". Once it's connected, the speed is fine, so I don't believe it's a speed issue. Further, when I use dig to test out my DNS abilities I get no problem:

Code:

[drew@Lugh drew]$ dig www.cnn.com

; <<>> DiG 9.2.3 <<>> www.cnn.com
;; global options:  printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 2452
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;www.cnn.com.                   IN      A

;; ANSWER SECTION:
www.cnn.com.            80      IN      A       64.236.16.52

;; Query time: 11 msec
;; SERVER: 192.168.0.1#53(192.168.0.1)
;; WHEN: Sun Aug 21 09:22:36 2005
;; MSG SIZE  rcvd: 45


This is an immediate response, and it can't be cached because I never mentioned cnn.com to my Gentoo box before that dig command.
So I'm getting a DNS answer right-away; then why is Firefox sitting there saying "looking up..."?

I spent the summer in a densely populated metropolitan area and had no problem browsing, but I come back to my home town (much, much smaller place) and this happens. This was also an issue *before* I left for the DC area.

Background information:

*I'm behind a netgear router, MR814V2. This is not my choice, I recently came under certain circumstances and am borrowing this one from a friend.

*I'm on a 1Mb cable connection with a Motorola surfboard modem.

And just for thoroughness, because I'm convinced my files are messed up:

/etc/hosts:
Code:

[drew@Lugh drew]$ more /etc/hosts
127.0.0.1       localhost localhost.localdomain


/etc/resolv.conf
Code:

[drew@Lugh drew]$ more /etc/resolv.conf
nameserver 192.168.0.1


/etc/conf.d/net
Code:

iface_eth0="dhcp"
gateway="eth0/192.168.0.1"



And 192.168.0.1 is the Netgear router.


I'm lost. Please educate me. And thanks in advance.
_________________
"Of course, that's just my opinion. I could be wrong."

-Dennis Miller
Back to top
View user's profile Send private message
ikaro
Advocate
Advocate


Joined: 14 Jul 2003
Posts: 2527
Location: Denmark

PostPosted: Sun Aug 21, 2005 2:58 pm    Post subject: Reply with quote

what if you add the nameservers from your ISP into the resolv file, instead of the router ?

see if you get the same delay using 'dig www.cnn.com @192.168.0.1'
_________________
linux: #232767
Back to top
View user's profile Send private message
drawsmcgraw
Tux's lil' helper
Tux's lil' helper


Joined: 11 Oct 2004
Posts: 126
Location: Starkville, Mississippi USA

PostPosted: Sun Aug 21, 2005 3:31 pm    Post subject: Reply with quote

Code:

[drew@Lugh drew]$ dig www.cnn.com @192.168.0.1

; <<>> DiG 9.2.3 <<>> www.cnn.com @192.168.0.1
;; global options:  printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 55287
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;www.cnn.com.                   IN      A

;; ANSWER SECTION:
www.cnn.com.            80      IN      A       64.236.16.52

;; Query time: 6 msec
;; SERVER: 192.168.0.1#53(192.168.0.1)
;; WHEN: Sun Aug 21 10:29:15 2005
;; MSG SIZE  rcvd: 45


No problem there....

I thought about placing the DNS servers into my resolv.conf but this cable modem is a black box and I don't know any other way to find out my name servers. Doesn't seem to be a problem using my router anyway... I have this same issue with Thunderbird as well. Also, interestingly, when I try to ping a site I got nothing:

Code:

[drew@Lugh drew]$ ping www.cnn.com
PING www.cnn.com (64.236.16.52) 56(84) bytes of data.

--- www.cnn.com ping statistics ---
21 packets transmitted, 0 received, 100% packet loss, time 19999ms

[drew@Lugh drew]$


Though this is splotchy at best. Sometimes I'll ctrl-C and it will report that it received one or all replies back so... I'm still at a loss....
_________________
"Of course, that's just my opinion. I could be wrong."

-Dennis Miller
Back to top
View user's profile Send private message
ikaro
Advocate
Advocate


Joined: 14 Jul 2003
Posts: 2527
Location: Denmark

PostPosted: Sun Aug 21, 2005 3:54 pm    Post subject: Reply with quote

maybe the router is filtering icmp packets.
email your isp and ask them for the nameservers.
usually its on their website, under support and faq.
_________________
linux: #232767
Back to top
View user's profile Send private message
drawsmcgraw
Tux's lil' helper
Tux's lil' helper


Joined: 11 Oct 2004
Posts: 126
Location: Starkville, Mississippi USA

PostPosted: Sun Aug 21, 2005 4:03 pm    Post subject: Reply with quote

Well sunuvabitch! I found a section in the router that tells which DNS servers it has. Plugged those into /etc/resolve.conf and I'm doing much better! Again, I've overlooked something :oops:

So I guess what was happening was that my box was treating the router like a DNS server and, naturally, the router had no idea what it was talking about and I was just waiting for.... well, what happened if all I had was the router for the DNS server? There was no other IP for it to fail over to... somehow the router forwarded the requests to the DNS servers that it knows??? I don't understand.... but at least I can surf better! Thanks a bunch!
_________________
"Of course, that's just my opinion. I could be wrong."

-Dennis Miller
Back to top
View user's profile Send private message
laurentgedm
Apprentice
Apprentice


Joined: 23 Feb 2005
Posts: 164
Location: Brussels

PostPosted: Mon Aug 29, 2005 1:58 pm    Post subject: Reply with quote

The thing is, in WinXP the name server is configured as the router's ip. And it's fast.

I think it's strange that digging, emerging, ping-ing is fast and not web browsing. I'm talking about the name resolving (is this the right word? english isn't my motherlanguage).
Back to top
View user's profile Send private message
drawsmcgraw
Tux's lil' helper
Tux's lil' helper


Joined: 11 Oct 2004
Posts: 126
Location: Starkville, Mississippi USA

PostPosted: Mon Aug 29, 2005 2:05 pm    Post subject: Reply with quote

That's what I don't get. Name resolution only seems to be a problem when a browser or e-mail client is trying. I feel dumb now....
_________________
"Of course, that's just my opinion. I could be wrong."

-Dennis Miller
Back to top
View user's profile Send private message
laurentgedm
Apprentice
Apprentice


Joined: 23 Feb 2005
Posts: 164
Location: Brussels

PostPosted: Mon Aug 29, 2005 2:12 pm    Post subject: Reply with quote

Possibly a bug ine kdenetwork or something?
(i'm noob, please don't kill me if i'm saying something stupid)

Browsing www.gentoo.org in lynx was fast as hell, unlike in firefox...
Back to top
View user's profile Send private message
drawsmcgraw
Tux's lil' helper
Tux's lil' helper


Joined: 11 Oct 2004
Posts: 126
Location: Starkville, Mississippi USA

PostPosted: Mon Aug 29, 2005 2:23 pm    Post subject: Reply with quote

Interesting... Does Firefox use kdeNetwork? I'm curious mostly because I'm running Fluxbox, and kdeNetwork makes me think of, well, KDE.
_________________
"Of course, that's just my opinion. I could be wrong."

-Dennis Miller
Back to top
View user's profile Send private message
laurentgedm
Apprentice
Apprentice


Joined: 23 Feb 2005
Posts: 164
Location: Brussels

PostPosted: Mon Aug 29, 2005 2:34 pm    Post subject: Reply with quote

This was just an idea. I'm using kde, so i thought of it.
But as dns resolving is fast in consoles and slow in X clients, couldn't it be a problem with an intermediate layer?
Back to top
View user's profile Send private message
drawsmcgraw
Tux's lil' helper
Tux's lil' helper


Joined: 11 Oct 2004
Posts: 126
Location: Starkville, Mississippi USA

PostPosted: Mon Aug 29, 2005 2:40 pm    Post subject: Reply with quote

Very likely. But, being just a user, I have no idea where to start on that.
_________________
"Of course, that's just my opinion. I could be wrong."

-Dennis Miller
Back to top
View user's profile Send private message
Venoms
n00b
n00b


Joined: 19 Jun 2005
Posts: 26

PostPosted: Mon Aug 29, 2005 8:45 pm    Post subject: Reply with quote

I've been using both flux and kde, both are slow as h*ll compared to windows xp.
At the moment, my Gentoo is down...disk replacement, so I can't try anything but I did everything you guys said but with no improvement. The nameres are slow and ping's are fast as expected.
Btw, I tried Opera Firefox and that default one in kde, can't remember the name, all have same speed.
I had static dns from my isp so that was not the problem. Maby it could be the dns cache you talked about. I will try that in next install, and let you know the result.

edit:

If you go to a site that you never visited before, then it could not be cached. The second time it still slow, but not that slow, because of the cache in the browser, I'll guess. So, a dns cache would do something nice here...
Back to top
View user's profile Send private message
laurentgedm
Apprentice
Apprentice


Joined: 23 Feb 2005
Posts: 164
Location: Brussels

PostPosted: Wed Aug 31, 2005 3:35 pm    Post subject: Reply with quote

Are we all running an amd64 system?

I'm filing a bug.

EDIT: Bug#: 104389
Back to top
View user's profile Send private message
Venoms
n00b
n00b


Joined: 19 Jun 2005
Posts: 26

PostPosted: Wed Aug 31, 2005 4:51 pm    Post subject: Reply with quote

Quote:
Are we all running an amd64 system?


Nop, I have one Intel P4 2,8 ghz Prescott, 1,5gb ram 2x120gb Maxtor sata 1x40gb maxtor 133 Pata and Ati r 9600 256

Broadband 26 mbit
Back to top
View user's profile Send private message
laurentgedm
Apprentice
Apprentice


Joined: 23 Feb 2005
Posts: 164
Location: Brussels

PostPosted: Tue Sep 06, 2005 2:00 am    Post subject: Reply with quote

All right. There are too few people who have this problem, they won't help us. I didn't file my bug correctly, i should have mentioned more threads talking about slow dns.

The only solution i see is a patch called winxp. It always works. Ugly, but it always works.

Good luck.


Last edited by laurentgedm on Tue Sep 06, 2005 12:57 pm; edited 1 time in total
Back to top
View user's profile Send private message
nixnux
n00b
n00b


Joined: 13 Jul 2005
Posts: 12

PostPosted: Tue Sep 06, 2005 4:03 am    Post subject: Reply with quote

A long time ago I had problems with this too. I couldnt resolve any hostnames in under 10 seconds. Going to a webpage would go slow, then it'd start to load up an add or anything that requires another lookup and it'd hang for another 10-20 seconds. It also worked fine in windows. What I did find out though is that windows seems to take a dns that isnt online, or really slow, and ignore it and go on to the next. What I did was change my settings in my router so that it reported worked dns's to my dhcp clients. My problem was that it tried to use a dead dns before each lookup. Hope this helps
Back to top
View user's profile Send private message
File_Mangler
n00b
n00b


Joined: 06 Dec 2005
Posts: 2
Location: Colorado

PostPosted: Tue Dec 06, 2005 3:45 am    Post subject: Reply with quote

The problem isn't specific to Firefox or Gentoo either. I've had similar issues when using Knoppix v3.9 and newer. The wm I used was KDE. Browsers tried: Konquerer, Netscape, and Firefox. I haven't tested other wm's, although Links works just fine (nonGUI).
Back to top
View user's profile Send private message
Decibels
Veteran
Veteran


Joined: 16 Aug 2002
Posts: 1623
Location: U.S.A.

PostPosted: Tue Jan 03, 2006 9:26 pm    Post subject: Reply with quote

Two things I did to speed up my browsing worked for me:
Firefox is defaulting to IPV6 lookup, so changed that to false:
Code:
about:config and change 'network.dns.disableIPv6' to true

Then pinged my ISP's DNS boxes, found my secondary was faster by half, so switched the primary and secondary.
Then restared the network.

Much faster.
_________________
Support bacteria – they’re the only culture some people have.”

– Steven Wright
Back to top
View user's profile Send private message
PaulBredbury
Watchman
Watchman


Joined: 14 Jul 2005
Posts: 7310

PostPosted: Tue Jan 03, 2006 9:58 pm    Post subject: Reply with quote

If DNS resolving is the problem, then the simple answer is to run bind, so you are not dependent on your ISP's nameservers.
_________________
Improve your font rendering and ALSA sound
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