Extremely slow DNS lookups and/or page loading

RESOLVED WORKSFORME

Status

()

Firefox
General
RESOLVED WORKSFORME
10 years ago
7 years ago

People

(Reporter: Anthony DiSante, Unassigned)

Tracking

({perf})

3.0 Branch
x86
Linux
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

10 years ago
User-Agent:       Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9) Gecko/2008061017 Firefox/3.0
Build Identifier: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9) Gecko/2008061017 Firefox/3.0

Sometimes Firefox loads new pages quickly, but often -- perhaps about half the time -- pages load extremely slowly, with the status bar saying "Looking up whatever.com" or "Connecting to whatever.com".  When this happens, it's for every site I try to visit, not one particular site.  The lookups take anywhere from 10 to 30 seconds.

When this problem isn't happening, pages load in just a second or two over my Comcast cable connection.

It's especially bad on maps.google.com; I'll go there and it'll load, but then trying to zoom in results in some or all of the visual blocks failing to load, or loading really slowly.  It's so bad that, while it's trying to load, I can open Opera on the same system, go to maps.google.com, and bring up the same thing; then do the same thing on my iPhone over the EDGE network; then go back to Firefox and it still hasn't loaded.

I've tried creating a new Firefox profile, but that made no difference.

I think the only things I do with Firefox that are somewhat abnormal are 1) having lots of tabs open, generally 30-50, and 2) having lots of groupmarks of those tabs, generally about 1 per day from the past ~3 years, which is a habit I got into due to the fact that Firefox crashes all the time unless you disable all the plugins, which was hard to do before Firefox 3.  My bookmarks file is about 8 MB.  But again, this slowness problem isn't there all the time, so it seems like the many tabs & groupmarks must not be a problem in general.

Also, this is probably a separate bug, but when Firefox is being all slow like this, if I attempt to switch to another tab, it often causes the whole browser to lock up until that lookup finishes.


Reproducible: Sometimes
(Reporter)

Updated

10 years ago
Version: unspecified → 3.0 Branch

Comment 1

10 years ago
your platform probably has broken ipv6 lookups enabled. 

try about:config network.dns.disableIPv6 = true

Comment 2

10 years ago
Been having the same issue here, even though IPv6 lookups are already disabled. It's been going on for several months through the release candidates to 3.0.1 I'm using now, though I'd been ignoring it thinking it was some network issue... but it has been so persistent that it made me suspicious and I started investigating.

The problem strikes fairly consistently when browsing ebay, of all places. I'll notice some images aren't loading, and opening links in new tabs hangs on "Looking up ebay.com..." Which seems rather ridiculous since firefox should already know the IP when I opened the site less than a minute ago and it's still sitting there, open on the screen. I'll also open a tab try to go to a completely unrelated site like google, and sure enough it hangs on "Looking up google.com...". This situation persists for upwards of ten minutes at times and no amount of refreshing or trying different sites will speed this up within firefox. However, if I open an alternate browser it can load sites immediately. Task killing firefox and reopening it also allows it to resume making dns lookups, at least until they hang again.

The issue persists even with a fresh install of firefox, without add-ons, on a brand new profile. DNS lookups using host/nslookup also all work immediately while firefox is having trouble.

Comment 3

10 years ago
I forgot to mention... this also happens under Windows XP SP3, so it's probably not limited to the Linux build.

It's almost as though something's getting stuck in the pipe and firefox just chokes on it for a while, unable to get to anything new.
(Reporter)

Comment 4

10 years ago
> your platform probably has broken ipv6 lookups enabled. 
> 
> try about:config network.dns.disableIPv6 = true

I tried this; it did not fix the problem.

I'd like to second the above comment by "Target": it's especially ridiculous that this happens when trying to browse to a page on a domain that you've been browsing on for the past 10 minutes, and suddenly Firefox can't resolve the domain.  That's ridiculous because Firefox knew the domain's IP address about 2 seconds ago; why has it suddenly forgotten??

Another thing to note about this problem is that, while Firefox is temporarily frozen because of this issue, my system monitors show no CPU usage and no network usage.  Firefox appears to be just sitting there doing nothing.

One fairly reliable way to reproduce this issue is to have about 30 tabs open in Firefox, then close Firefox, wait a few seconds, and re-launch Firefox so that it opens with all 30 tabs showing.  Firefox will load a few of the tabs immediately, but most of them will show the spinner on the tab, indicating that the page is loading.  But if/when you click on one of those still-loading tabs, Firefox does the temporarily-locked-up thing for sometimes 30-60 seconds.  Then eventually it'll come back from the twilight zone and display that tab (whether still loading or finished loading), but the same thing happens when you try to click on any of the other tabs.  And again, there's no CPU nor network usage during these times.  The result is that opening Firefox with this many tabs takes about ~5 minutes -- not because it takes a lot of CPU time or network time to download & display the pages, but because you have to wait out several periods of the browser being completely unresponsive for 30-60 seconds.

Updated

9 years ago
Keywords: perf

Comment 5

9 years ago
Same issue here with FF3.5.1 winxp.

"Loading" on tab, but nothing on status bar
What type of router are you using?

Comment 7

9 years ago
I don't have router, I'm using the ADSL, the router should on the ISP side, or you may mean the ADSL modem is the router. But my question is why other browers are ok with this?

Comment 8

9 years ago
I captured the picture, it will take more than one minute to solve the DNS

http://rockthearth.blogspot.com/2009/08/firefox-looking-up-dns-issue.html
While Firefox is in this state can you please run a "telnet audio.pconline.com.cn 80" at the same time. Do you get a prompt or a timeout too?

Comment 10

9 years ago
Now the DNS is ok with audio.pconline.com.cn, it's not ok with twitter.com, it's looking up twitter.com now, but I have already set the IP in host file for twitter. So I think the problem is not at the server side.

Comment 11

9 years ago
For the Comment #10, I think I made a mistake, I may used the proxy
Please follow my steps in comment 9 with a domain where DNS resolution times out. Thanks.

Comment 13

9 years ago
I can confirm this issue. I am running Iceweasel 3.0.12 and see exactly the same behavior.

When I see the behavior I can start another browser (Konqueror) and get access to the websites with no problem at all.

I have analyzed the network traffic. I assumed that that DNS might have to timeout, but that is not the case. Here is I am at maps.google.com (which refers to khm.google.com):

16:00:40.266158 IP 10.0.0.113.47496 > 10.0.0.8.53: 24778+ A? khm.google.com. (32)
16:00:40.298030 IP 10.0.0.8.53 > 10.0.0.113.47496: 24778 5/6/6 CNAME khm.l.google.com., A 66.102.9.91, A 66.102.9.93, A 66.102.9.136, A 66.102.9.190 (308)

As you can see I get a reply from the nameserver 10.0.0.8 arrives 32 ms later, but Firefox seems to ignore this reply. 

I opened a new tab and entered another website. The address of this website was also looked up correctly by DNS immediately. But the DNS reply was also ignored by Firefox.

Only after several minutes does Firefox start loading. Sometimes this can be sped up by pressing refresh.

My network.dns.disableIPv6 has been set to true for the past month and did not solve the problem.

Comment 14

9 years ago
Ole Tange,

Thanks for the verification

Comment 15

9 years ago
I read somewhere that someone successfully fixed this by starting a new profile. I have just tried renaming .mozilla to .mozilla2 and have been unable to provoke the error again.

Could others who experience this problem confirm if this fixes the issue?

Comment 16

9 years ago
I have run with the new profile for the past few days and normally I experience the problem at least 5 times per day, but I have not experienced the problem since I renamed .mozilla to .mozilla2. This is even though network.dns.disableIPv6 = false. So IPv6 is clearly not the culprit in my setup.

I added flashblock as plug-in yesterday and still do not see any problems. Now I will try adding some of the other plugins to see if they cause the problem.

Comment 17

9 years ago
renamed .mozilla to .mozilla? How and where to rename the file

I use the Winxp, C:\Documents and Settings\Administrator\Application Data\Mozilla\Firefox, open the profiles.ini 

add following lines, then save, open firefox, new profile Frank created
[Profile2]
Name=Frank
IsRelative=1
Path=Profiles/7bbtrocp.Frank
Default=1

Comment 18

9 years ago
I am not a Windows Guru, but from the path you sent I believe my .mozilla corresponds to your C:\Documents and Settings\Administrator\Application
Data\Mozilla

So try closing Firefox, then rename C:\Documents and Settings\Administrator\Application
Data\Mozilla to C:\Documents and Settings\Administrator\Application
Data\Mozilla2, then start Firefox.

Let us know if this solves the issue.

Comment 19

9 years ago
I think this may be caused by the Add-on, here I captured the Addons window http://rockthearth.blogspot.com/2009/08/firefox-looking-up-dns-issue.html 

Create a new profile will keep the plugins, but can't keep addons. 

I will try to rename this directory.

Comment 20

8 years ago
I've had this same problem pop up just recently on both work and home machines. Home has IPv6 off, work has IPv6 on, so it doesn't seem to be related to that.

Firefox will initially work normally. Usually what happens is that when refreshing a heavily visited site it will progress part way through loading and then make it no further - just the spinning progress meter, usually with the status bar saying "Waiting for DOMAIN...". Opening a new tab and going to that site (or stopping that tab and hitting refresh again) will start the loading process again, but the status bar will display "Looking up DOMAIN..." and go no further.

While this is happening, Firefox can load other pages on other domains without issue (unless they too have hit the same problem), and other applications have no trouble loading the page (and looking up the domain) Firefox has apparently stumbled over.

The sites that seem most affected by this are ones that are often refreshed and have a lot of images - I'm assuming there is some relationship to how often a domain has to be looked up or data from an IP is requested. So far firefox has not stumbled on google.com - it is used a lot, but the number of images and whatnot is low so overall the number of requests to google.com is low compared to some image heavy sites.

Restarting firefox fixes the problem, but it will re-occur eventually - in one case it took only one refresh of the affected page to trigger the problem, in other cases it takes a few hours of use. Reinstalling firefox has no effect, although I've yet delete my profile and try a new one.

The home machine is running Firefox 3.5.2 on Windows 7 build 7100, while the work machine is running Firefox 3.5.2 on Windows Vista Enterprise.

Comment 21

8 years ago
@ bugzilla@mdb.id.au:

Can you try to remove your Mozilla data/config dir? Or create a new profile. I used to have the same behaviour that you describe, but I have not had the problem after I did:

https://bugzilla.mozilla.org/show_bug.cgi?id=446249#c16
https://bugzilla.mozilla.org/show_bug.cgi?id=446249#c18

Comment 22

8 years ago
@ Ole Tange

That _seems_ to have improved things. To 'change profiles' I moved C:\Users\[USERNAME]\AppData\Roaming\Mozilla\Firefox\Profiles\[PROFILEID].default to [PROFILEID].default.HIDDEN and C:\Users\[USERNAME]\AppData\Roaming\Mozilla\Firefox\profiles.ini to profiles.ini.HIDDEN.

After hammering several sites that were suffering the problem for a while things are still working, unfortunately I can't be 100% sure if it's going to stay that way since while the issue is reproducable, it's not so on command.

My old profile has been ported between computers over various versions of Firefox, so it is possible that something has 'come loose' along the way. I'm going to slowly re-integrate bits of my old profile (extensions, bookmarks etc) and see if it remains stable.

I'll post comments if the issue comes back after putting back certain parts of my old profile.

Comment 23

8 years ago
Sadly that doesn't seem to have done it. I logged what I did though:

-----
New Profile (shut down, move old profile directory, and move profile.ini, restart)
Shut down
Replaced sessionstore.js with old profile's (kept original as backup)
Replaced cookies.sqlite with old profile's (kept original as backup)
Replaced places.sqlite with old profile's (kept original as backup)
Restart
Installed addons:
	Adblock Plus 1.1.1
	Cooliris 1.11.1
	Coral IE Tab 1.50.20090807
	DownloadHelper 4.6.2
	Rikaichan 1.06
	Rikaichan Japanese-English Dictionary 1.11
	NoScript 1.9.8.8
	Tab Mix Plus 0.3.8.1
Restart

Problem repeated

Restored sessionstore.js (Bookmark all tabs, shut down, delete sessionstore.js and put the default one back, restart, reload bookmarks)

Problem repeated

Restored places.sqlite (Backup bookmarks, shut down, delete places.sqlite and put the default one back, restart, restore bookmarks)

Problem repeated
-----

At this point I've decided to try a completely clean profile, re-import my bookmarks and return to the same usage pattern as before (I frequently run with 30+ tabs open, which may also be a contributing factor), this time with no add ons at all, no restored history and no restored cookies. I'll also disable javascript and java (they don't seem to be necessary to cause the problem, and I'm wary of going to most sites with those turned on). If the problem _still_ reoccurs then I think that confirms that a new profile doesn't fix it, and it's definitely not an add-on causing it.

Comment 24

8 years ago
If your profile dir is called:

C:\Users\[USERNAME]\AppData\Roaming\Mozilla\Firefox\Profiles\[PROFILEID].default

please close Firefox and try renaming the Mozilla Dir:

C:\Users\[USERNAME]\AppData\Roaming\Mozilla

to

C:\Users\[USERNAME]\AppData\Roaming\Mozilla.hidden

and start Firefox.

I regularly have 15 windows open with 10 tabs in each without seeing the problem, so 30+ tabs is not a problem.

Comment 25

8 years ago
@Ole Tange

OK, my original setup with no addons and nothing from the previous profile except re-imported bookmarks still triggered the problem after about a day. In fact, it triggered it just before I went to bed so I left it 'looking up...' overnight. Time didn't fix it - it was still 'looking up' 8 hours later, and refreshing just got it stuck there again.

So I followed the instructions from your last comment and shut down, moved C:\Users\[USERNAME]\AppData\Roaming\Mozilla to C:\Users\[USERNAME]\AppData\Roaming\Mozilla.bak and restarted. Got the brand new profile and started using it. It lasted about 6 hours before the problem surfaced again.

At this point I'm going to have to go with this build being broken. If the issue keeps triggering I'll have to see if downgrading to the 3.0 branch helps like I've seen suggested.
This is a mass search for Firefox General bugs filed against version 3.0 that are UNCO and have not been changed for 200 days.

Reporter, please update to Firefox 3.6.10 or alter. Firefox 3.0 is no longer supported and is no longer receiving updates. After you update, please create a fresh profile, http://support.mozilla.com/kb/managing+profiles, and test to see if your bug still exists. If you still the bug, then please post a comment with the version you tested against, and the problem. If the issue is no longer there, please set the RESOLUTION to  RESOLVED, WORKSFORME.
Whiteboard: [CLOSEME 2010-11-01]

Comment 27

7 years ago
I have not seen this problem for ages. Currently running Iceweasel 3.5.12.

As it was a periodic problem I cannot tell when it was solved.

Comment 28

7 years ago
WFM per comment 27. Thanks Ole
Status: UNCONFIRMED → RESOLVED
Last Resolved: 7 years ago
Resolution: --- → WORKSFORME
Whiteboard: [CLOSEME 2010-11-01]
You need to log in before you can comment on or make changes to this bug.