Join the AMA (Ask Me Anything) with the Firefox leadership team to celebrate Firefox 20th anniversary and discuss Firefox’s future on Mozilla Connect. Mark your calendar on Thursday, November 14, 18:00 - 20:00 UTC!

Ovo će web mjesto raditi na ograničen način, dok obavljamo održavanje stranice. Ako neki članak ne riješi tvoj problem i ako želiš postaviti pitanje, naša zajednica za podršku spremna je pomoći na Twitteru @FirefoxSupport i na Redditu /r/firefox.

Pretraži podršku

Izbjegni prevare podrške. Nikad te nećemo tražiti da nas nazoveš, da nam pošalješ telefonski broj ili da podijeliš osobne podatke. Prijavi sumnjive radnje pomoću opcije „Prijavi zlouporabu”.

Saznaj više

Firefox 120.0.1 Memory Leaks, Windows 11 & 10, not a new issue

  • 10 odgovora
  • 5 ima ovaj problem
  • 4 prikaza
  • Posljednji odgovor od cor-el

more options

Firefox uses too much memory, sometimes 20GB on a 32GB Windows machine. It's usually one or two threads which are hogging incredible amounts of memory. This time I had about 30 tabs open.

Today I tried Firefox about:memory "Minimize Memory Usage" several times, and it was largely ineffective.

I did a "create memory dump file" of one 5+GB bloated thread using task manager, but can't find a way to upload the compressed archive with this report for analysis. Finding a way to report this issue was quite a challenge. It seems most help avenues are now missing/moved, and other reports of this type of issue are "Archived".

I tried killing the 2 bloated Firefox threads and checked for tabs which might be missing or malfunctioning. Everything continued to run normally while more than 10GB of memory was returned to system use. Leaving these bloated threads overnight doesn't improve anything, in fact I can often get up and find my machine is completely out of memory because Firefox consumed it all. My smallest machines have 16GB RAM.

These memory issues aren't new. I've been reporting them off and on for more than a decade. They get better for a few months after reporting, then they get bad again in a few more months. The battle to get memory leaks fixed is continuous while Firefox springs more leaks.

I'd like to give you the memory image I generated so you'll at least have some real data to look at and analyze for this report.

The attached task manager snapshot image is a very minor example of this issue. The numbers keep increasing like there are one or more large memory leaks.

Firefox uses too much memory, sometimes 20GB on a 32GB Windows machine. It's usually one or two threads which are hogging incredible amounts of memory. This time I had about 30 tabs open. Today I tried Firefox about:memory "Minimize Memory Usage" several times, and it was largely ineffective. I did a "create memory dump file" of one 5+GB bloated thread using task manager, but can't find a way to upload the compressed archive with this report for analysis. Finding a way to report this issue was quite a challenge. It seems most help avenues are now missing/moved, and other reports of this type of issue are "Archived". I tried killing the 2 bloated Firefox threads and checked for tabs which might be missing or malfunctioning. Everything continued to run normally while more than 10GB of memory was returned to system use. Leaving these bloated threads overnight doesn't improve anything, in fact I can often get up and find my machine is completely out of memory because Firefox consumed it all. My smallest machines have 16GB RAM. These memory issues aren't new. I've been reporting them off and on for more than a decade. They get better for a few months after reporting, then they get bad again in a few more months. The battle to get memory leaks fixed is continuous while Firefox springs more leaks. I'd like to give you the memory image I generated so you'll at least have some real data to look at and analyze for this report. The attached task manager snapshot image is a very minor example of this issue. The numbers keep increasing like there are one or more large memory leaks.
Priložene slike ekrana

Svi odgovori (11)

more options

Using about:processes shows the biggest offending URL's are Facebook (2GB for each Facebook tab), and OKCupid (was using 5GB). OKC let go of memory some 15 seconds after I gave it focus. I closed both sites, we'll see how it goes from here. The other sites all seem to run without issue. I have no idea why FB and OKC would cause so much trouble. I tend to keep them open so I can look at them when there is time, and without having to re-login/Set Up. Are these sites using Firefox code with problems? Or are the site implementations defective?

more options

You can check the about:memory and about:processes pages for info about all processes.

See also the about:unloads page for info about the tabs.

more options

Websites can have memory leaks in their own code and slow leaks may go unnoticed. It may help to streamline page content with something like uBlock Origin.

Craiga said

find my machine is completely out of memory because Firefox consumed it all.

Tabs should be unloaded when getting low on memory, check that browser.tabs.unloadOnLowMemory is default true in about:config. You can see how it is prioritizing tabs by visiting about:unloads.

You may want to limit processes to one per site by changing dom.ipc.processCount.webIsolated to 1.

more options

zeroknight said

Websites can have memory leaks in their own code and slow leaks may go unnoticed. It may help to streamline page content with something like uBlock Origin.

Craiga said

find my machine is completely out of memory because Firefox consumed it all.

Tabs should be unloaded when getting low on memory, check that browser.tabs.unloadOnLowMemory is default true in about:config. You can see how it is prioritizing tabs by visiting about:unloads.

You may want to limit processes to one per site by changing dom.ipc.processCount.webIsolated to 1.


I run uBlockOrigin on all my systems.

browser.tabs.unloadOnLowMemory is, and was, set to the default "true"

dom.ipc.processCount.webIsolated I'll give this one a try, it was set to 4.

I'm trying Facebook and OKCupid in MS Edge. I want to gather data to see if Edge has the same problems with these sites. My recollection from past use is that Chrome, Chromium, and MS Edge don't.

Thank you for your suggestions.

more options

For comparison, after leaving MS Edge running all night with Facebook, OKCupid, GMail, a power supply parts vendor pages open, it is still using less than 1GB memory for everything and everything is still functioning as I'd expect.

Firefox has the usual assortment of tabs <30. I checked task manager and killed (Ended Task) any Firefox non-main entry using more than 500MB, there were 3. Firefox continues to run as if nothing happened, but now I have 10% of my 32GB back. Apparently, whatever Firefox is doing with this memory isn't needed. Firefox is running 44 tasks.

Firefox has some real memory usage/hogging problems. [Currently using over 4GB of memory and nothing is particularly wrong, just idling. By comparison, MS Edge is using <900MB. Thunderbird is better, but has similar memory problems, probably in shared code.

I keep using Firefox for privacy and security reasons. I use features like Mozilla Sync (all except passwords which I don't want stored anywhere outside my own network), Multi-Account Containers across 7 Windows/Linux machines I use regularly. Multi-Account Containers thwarts some badly implemented web site logins. Firefox otherwise works well, it's just the memory gluttony issues that keep tripping things up. I've had it use all 32GB of RAM after leaving it running for a few days and working with ~50 tabs while doing research and running simulations.

I don't trust the personal information sale business models of other browser creations owned by Google or Microsoft with any of my information, but am quite proficient with their product operation when I must (decades of experience). Not all their information usage is bad or objectionable, but enough is that I'll avoid their use. You'd be surprised at what interesting and marketable things A.I. can dig out of a pile of your personal communication.

I'd like to see Firefox memory over consumption addressed. For at least a decade, this can has been kicked down the road. Yes, I know how difficult memory usage can be to track, isolate, and address. This memory consumption needs to be addressed as a serious ongoing performance issue/effort in Firefox and other Mozilla products.

Why do I care? Mozilla is providing ground breaking privacy and security advancements. I'd like to see this effort continue and improve to the point where there is no real viable alternative to Mozilla products.

more options

Craiga said

I use features like ... Multi-Account Containers

Containers can increase memory consumption considerably since resources cannot be shared between them. Total Cookie Protection (first party isolation) similarly causes duplication of resources. Privacy features are not without a cost.

If you want tab unloading to be more aggressive and kick-in earlier before you run out of memory, you can increase browser.low_commit_space_threshold_mb.

more options

firefox memory usage is getting worse. granted I only have 8G of ram but it has never run so slow in the past. need a fix. tried "Minimize Memory Usage" no help. Firefox should not consume so much memory that the pc is virtually locked up.

more options

zeroknight,

Yes, I'm certain features like Multi-account Containers use more memory. At most I'd expect 2x that of MS Edge and/or Chrome, but not the 10x-40x that I'm seeing.

As I have been saying, and as "katinfoco" just reiterated, there is a real and serious problem with Firefox memory consumption. I do not expect this Mozilla Firefox memory consumption problem to go away or get better if it continues to be ignored. It is going to take a programmer with serious coding skills and abilities to look at the problem, find, and fix code which either isn't releasing memory when it should, or implements a defective algorithm which consumes large amounts of memory under certain conditions.

If it were me, I'd start with sites known to cause problems like Facebook.com and OKCupid.com and figure out why these two sites cause Firefox to consume alarming amounts of memory over days of usage when competing products like MS Edge and Chrome do not have these problems with the same usage patterns on these sites. I seriously doubt 10x-40x more memory usage can be explained away as "you're using Multi-Account Containers", or some other nifty Firefox feature. I would expect Firefox to consume little memory, as it does on so many other site implementations, where Firefox does behave appropriately on my systems. And BTW, I see the same memory consuming problems with Firefox in MS Windows and Ubuntu Linux.

This problem is bad enough that I now run two browsers, MS Edge and Firefox. Any site URL which causes system damaging memory usage in Firefox, gets moved to MS Edge which doesn't experience these wild runaway memory consuming moments.

This said, I did try browser.low_commit_space_threshold_mb. Good idea, but it doesn't help.

more options

On Linux you can use browser.low_commit_space_threshold_percent and remember to enable browser.tabs.unloadOnLowMemory. With large enough values for the low_commit_space prefs, processes will be unloaded before getting too large which works for me currently on Linux.

Does it still happen in a new profile without signing into sync? An easy way to test a new profile is to install Developer Edition and see if it happens there or refresh your existing profile.

more options

The problem with these solutions (which are appreciated) is they are just band-aids I can slap on to Firefox in a desperate attempt to keep my system usable while Firefox keeps hemorrhaging system memory from what I suspect is code which needs something like Lint run on it.

I read this in another group this morning from a user who is also battling Firefox behaviors. This sentiment reflects my concerns for Mozilla Firefox:

I've found a solution to the problem: run the music players in MS Edge.

Problem solved! 
 
So it looks like I'm going to have to finally learn how to use MS Edge.


The problem is these failures cause user frustration and consume too much individual time when the real problem is the product needs to be fixed/repaired/addressed/rewritten. People are busy and have alternatives. Some are doing important things like designing medical equipment to save lives, or doing research to save lives. Having to constantly be pulled off task because of Firefox misbehavior is causing Firefox to lose market share. As an example, Thunderbird is doing a rewrite of a large section of product code to improve code speed, behavior, and maintainability for the product. Perhaps it's time to consider this kind of attention for Firefox code.

https://gs.statcounter.com/browser-market-share/

If Chrome or MS Edge addressed privacy to the level that Firefox does, changing would be a no-brainier. If default poor memory behavior isn't addressed this decision will move from potential no-brainier to necessity.

Izmjenjeno od Craiga

more options

You can create a new profile as a quick test to see if your current profile is causing the problem.

See "Creating a profile":

If the new profile works, you can transfer files from a previously used profile to the new profile, but be careful not to copy corrupted files to avoid carrying over problems.