Firefox, memory consumption up to 3GB

Gloster

Member
Joined
Feb 7, 2024
Messages
83
Reaction score
15
Credits
731
Ubuntu 22.04.01
Firefox : 129.0.2 (no snap, repository)

I did search for a solution, firefox answer : Close and restart, it works (after close and restart, diff. = 2GB)

I search for better solutions :

"Type “about:config” in your browser bar and adjust the following preferences (by double clicking on them) to free up some additional memory:

browser.cache.memory.capacity (set to 0)
browser.cache.memory.enable (set to false)
browser.sessionhistory.max_total_viewers (set to 0)
browser.tabs.animate (disable)"

I did, no improvement.

Perhaps there is a way not to load all, e.g.: of youtube playlist or something else.

But I have not found the "switch", any idea ?
 


you can try
about:memory
select "Minimize memory use"

I don't know how efficient this will be because I do the opposite: FF is using memory only without disk access. The options you have selected force cache to use disk (about:cache) however will not affect application memory use. There are other config options that may help. Some addons can help too (by blocking adds), obviously tab number,
disable predictor, preload, newtab. normandy, telemetry, safebrowsing
among the others.

I hope this will help a bit
 
How many tabs do you have opened? Right now I have 5 opened and I'm only using ~ 800 megs. (Granted, none are of Youtube.)
 
Ubuntu 22.04.01
Firefox : 129.0.2 (no snap, repository)

I did search for a solution, firefox answer : Close and restart, it works (after close and restart, diff. = 2GB)

I search for better solutions :

"Type “about:config” in your browser bar and adjust the following preferences (by double clicking on them) to free up some additional memory:

browser.cache.memory.capacity (set to 0)
browser.cache.memory.enable (set to false)
browser.sessionhistory.max_total_viewers (set to 0)
browser.tabs.animate (disable)"

I did, no improvement.

Perhaps there is a way not to load all, e.g.: of youtube playlist or something else.

But I have not found the "switch", any idea ?
There are a few considerations which arise about this issue.

The first query that arises is: what is firefox being busy with? If it has many tabs open at many websites which consume memory, with the user navigating between them, then it will inevitably have a higher memory usage. The nature of the website matters too. Memory usage is proportional in that way.

Perhaps knowing how the memory usage was measured could help, since excessive memory readings may be the result of a memory leak if it's not user usage. To get an idea of such leakage, if it's occurring, measuring memory usage should be done progressively over a reasonable period of time to see if the measure rises without much usage change. Memory leaks in firefox are known about. Here's a site with some info:

Normally the default configurations in about:config don't need adjustment for memory usage, rather, the issues of user usage and practice are probably the best first places to look at. To jump straight into altering configurations without looking at the user practices, the extensions, the addons, the themes and also any known issues with the particular release of firefox, is more liable to obscure the issues than clarify them.
 
Last edited:
Hm, further investigation leads to AdBlock Plus, the cause of memory leak by firefox.
I use 7 tabs per default, and 1-... <= 5 for further browsing. But further tabs will be closed, if no need to have them.
No further web extensions, I have.
And close and open firefox with 7 default tabs, leads to a memory usage of 1.2GB, instead of up to 3GB.

I am going to test it, with and without AdBlock Plus.
 
I use 7 tabs per default, and 1-... <= 5 for further browsing.
There is firefox task manager in "more tools" in firefox menu, use it to inspect which tab consumes the resources.
it's possible a web site that you visit is bad.
 
It seems Adblock Plus in conjunction with Firefox is the problem, it leads to a significant memory leak.
Since 3 days, I tested Firefox with Adblock Plus deactivated. The memory consumption as expected, up to 1.5 GB.
But if I close Firefox and reopen it with same Tabs, the memory consumption will be the same as before.
No further memory leak can be seen anymore.
 
It seems Adblock Plus in conjunction with Firefox is the problem, it leads to a significant memory leak.
Since 3 days, I tested Firefox with Adblock Plus deactivated. The memory consumption as expected, up to 1.5 GB.
But if I close Firefox and reopen it with same Tabs, the memory consumption will be the same as before.
No further memory leak can be seen anymore.
Good detective work. Fortunately there are quite a few other ad blockers available. The ones used here without issue are uBlock Origin, and Ghostery.
 
Yes of course uBlock Origin will be every where well pronounced. But I must confess, "never change a running system", Adblock Plus did its job, and if the problem is known, switch off firefox every 3 days, no problem anymore.

I think chromium is better

This will be a new thread, do it. I think an interesting discussion will be generated.
 

Members online


Top