Firefox consumes too much memory

11,091

Solution 1

Without specifying what you're doing exactly, it's hard to say this is an actual problem.

There's a common misconception that utilizing a lot of memory is bad. However, unused memory is a waste. It's like keeping a warehouse mostly empty because you think it's cleaner. By keeping as much as you can in memory, it saves having to go to disk and also reloading content needlessly. As long as the program is good about letting go of memory it doesn't absolutely require to other programs, it's not a problem.

If it's a memory leak on the other hand, that would be a big problem. You can check this by closing all your tabs except say a blank one. Then start loading other memory intensive programs. If you have another browser installed, like Chrome, start loading massive pages in it. If Firefox is still showing massive memory usage, then it's a leak. Your system will likely become sluggish from the other programs demanding unavailable memory.

It might be Firefox, but often it's an add-on or combination of add-ons causing the leak. You can disable all add-ons by starting Firefox in safe-mode from the terminal, firefox -safe-mode, to see if you have the same thing happen.

If you're saying that with just a few "light" websites open, and not doing anything in Firefox, that Firefox just starts taking up more and more memory, then it's plausible it's just Flash or some script going nuts. This is why I put "light" in quotes. It's unbelievable how badly some simple-looking sites are designed.

Solution 2

try restarting firefox with addons disabled. sometimes addons can cuase problems. @jippie i think he has checked from system monitor if the solution works then you have to remove some addons

Share:
11,091

Related videos on Youtube

Vivek
Author by

Vivek

Updated on September 18, 2022

Comments

  • Vivek
    Vivek over 1 year

    I have firefox version 11.0 and am running ubuntu 11.10. Firefox takes upto 850MB RAM with only six or seven tabs opened and all the tabs loaded with light weight websites only. I wonder why would a browser consume so much memory. It keeps increasing its memory consumption over time. I have 3GB RAM and most of the times firefox consumes upto 30% of my memory. How do I fix this?

    EDIT:

    The output of the command sudo iotop -oPa as asked by @Jippie

    enter image description here

    • Admin
      Admin about 12 years
      Why do you think Firefox is using 850MB, how do you measure memory usage? Why do you think this is a problem? Please elaborate.
    • Admin
      Admin about 12 years
      @jippie: I have an add-on called Memory Restart which shows the memory consumption of firefox and also I have noticed it in the system monitor. It is a problem for me because I am not able to load other applications.
    • Admin
      Admin about 12 years
      Try seeing if the leak happens in safe-mode. There are many poor add-ons that leak memory. Also, sometimes there are weird conflicts between add-ons that cause leaks.
    • Admin
      Admin about 12 years
      What do you mean by 'I am not able to load other applications.'?
    • Admin
      Admin about 12 years
      I have to run two IDEs Eclipse and Netbeans, other browsers like chrome, opera, and many other small applications. My system gets very slow if I load all these. But when I quit firefox, I get 30% free memory and the applications are back to normal.
    • Admin
      Admin about 12 years
      If this is the case, firefox should be way on top in sudo iotop -oPa. Can you confirm that?
    • Admin
      Admin about 12 years
      I have attached the screenshot of the command sudo iotop -oPa and I can also see that firefox tops the list while running top.
    • Admin
      Admin about 12 years
      You can also open about:memory?verbose in your Firefox address bar to see a detailed tree list of where your memory is being used... I'm not sure if this will help, but you might find that some sites aren't as light as they seem.
    • Admin
      Admin about 12 years
      @ChrisGranger: Thanks for the tip. I can see js occupying 50% of the total consumption.
    • Admin
      Admin about 12 years
      here too js approx. 50%, but my firefox is running like a breeze.
  • Vivek
    Vivek about 12 years
    I tried running firefox in safe mode and so far it is consuming very less memory, around 3.4%. The only reason why I use firefox is firebug. But I think firebug is the one that causes memory leak. So is there any workaround for this?
  • Chan-Ho Suh
    Chan-Ho Suh about 12 years
    You can try RAMBack. I tried it not too long ago and it did seem to help (eventually I was able to fix my own leak problem so I didn't need it anymore). It adds a clear (RAM) cache menu option to Tools. You seem to be up on technology, so I assume you have the latest updates. Only other thing I can think of is that from a brief Google search, it seems people have been complaining a long time about Firebug memory usage. I'd look in and ask in Firebug related forums and mailing lists about this.
  • Chan-Ho Suh
    Chan-Ho Suh about 12 years
    Oh, and of course, you can ask here on Ask Ubuntu! Perhaps start a new question asking how to reduce Firebug memory usage or something.