I realy love Unity, but the most of the time I have to use gnome-shell because I only have 1.5 GB of RAM and when I work I have to use all these apps: fogger, firefox, compiz efects, empathy, gwibber and some lenses. What can I do for get better efficiency of my memory usage without sacriface many features of Unity?

  • Welcome Cesasol: Have a look at this question as i think some of the answers may help you. askubuntu.com/questions/2194/… Aug 2, 2012 at 16:50
  • not use it? replace it with something else that actually works?
    – TheXed
    Aug 6, 2012 at 3:32

3 Answers 3


Check what processes are using the most memory. I use htop. I have seen that compiz leaks memory, and is the largest memory hog other than Firefox (which also leaks).

I get the best responsiveness (1.6GHz Pentium M with 2GB RAM) when I:

  • restart firefox to reclaim leaked memory
  • log out and log back in, to restart compiz and reclaim leaked memory
  • don't hibernate the machine; waking up from hibernating is slow due to the need to copy data from disk back into RAM

Other things that could improve your experience would be to investigate configuration options for the programs that are using the most memory and select options that as a result use less memory.


sorry for using a new answer again, but the button "add comment" doesnt work in my firefox for what reason ever :-)

That compiz is leaking memory its obviously. compiz is somehow a living dead. its buggy and has several other problems not just leaking. Firefox: i dont know if firefox is realy leeking much and to be honest, i have my doubts that it leaks much. tremendos amount of memory. Btw. comparing the memory situation before firefox was started and after it was closed does not say anything about the amount of leeked memory. Not only firefox cáches its memory the linux kernel do either. Most of the "lost" memory may be eg libraries in ram that arent used or used by an another app. the kernel decides when this memory will be freed. its the same thought i had explained in my first answer: let it be in memory for possible reuse until the used memory is realy needed. this strategy has two big advantages: no cpu time is needed to "clear" the ram. and if the ram is needed the kernel could imidiatly free that memory. If an app wants to reuse the code its already there. no need to load it from disk, which would be the slowest possibility. This not freed memory isnt needed by anyone, if it is needed kernel free it almost imidiatly. I also has my doubts that playing with config-options is a good idea, when you dont have deep knowlege of that app and a concret reason for it. smalering the ram-cash eg. in firefox will make it slower, eg when youve open many tabs, firefox may be forced to cache on disk and wouldnt be able to cache in ram. another good reason not to play with the config options is the thougt, that the coder has set the value. he is the person who knows his code best and usualy he will optimize this value on his own experiences and knowledge to an almost optimal result. Usualy lowering chaches will drecrease performance of an app. If apps realy leeks memory (and its not the usual few kilobytes), for eg. compiz then restarting may indeed improve responsibility for a short time.

  • vEliahKagan/jokerdino: Im sorry, but i dont understand what you want me to do :-( im not native english speaker and new to AskUbuntu ;-)
    – gemue2010
    Aug 6, 2012 at 3:30

It's a myth that Firefox or most other applications are leaking much memory. It's a completely misunderstanding of how Firefox and Linux manages memory. You see in your system memory that the amount of free memory seems to go down and the allocated memory of Firefox raises. But that has nothing to do with memory leaking. Firefox use this memory and don't give it back again because the loaded code may be reused later, without the need to load it again into memory. But if Linux or an application needs memory and there is no free Firefox or any other application will immediately give their reserved memory back to the system. The use of more memory makes Firefox and every other application faster as they would be, if those applications would give that memory back as soon as possible. So shutting down progs and restart them is usually not needed. Your memory isn't lost ;-)

Well of course every big application leaks some memory due to bugs eg. But that is usually a very small amount of memory (mostly some KB not MB)

Sorry EliahKagan/jokerdino: I do not realy understand what you want me to do. Im new to AskUbuntu and english isnt my native language ;-)

Yes, it would be really cool to have a tool that shows how much memory is really used and how many memory is only reserved. But I think it's hardly possible. It is possible to get information, how much memory which is reclaimable and how much is not is managed by the kernel. Applications marks memory to the kernel as reclaimable or not or as memory that isn't "allowed" to be reclaimed (eg. time critical parts). So, kernel is able to reclaim reclaimable memory, if needed. But the other half of the truth is, that every big app usually has its own memory-manager to decide which parts of the program is used or which part of memory is only reserved and how many memory is needed to be allocated from kernel.

Firefox has its memory manager (for eg. Firefox gives some information when opening about:memory), LibreOffice has also its own memory manager and all bigger apps has them too. If you would like to have the full information (not only related to kernel managed memory but also the apps managed memory) you had to get this information from the apps. I don't see an obvious possibility to get this information, because every app uses their own design of their memory management. You would be in a situation in which it is needed to understand and analyze all the different codes of all those apps. I think it's almost impossible to do.

EliahKagan/jokerdino: Sorry, I dont understand what you want me to do. Im new to AskUbuntu and english isnt my native language ;-)

  • You may want to expand this answer to explain how to find out how much of an application's totally allocated memory is available to be quickly relinquished when needed by another program, and how much is actually being used. Aug 3, 2012 at 7:48
  • @EliahKagan gemue2010 suggested an edit on the other answer to answer your comment. I have copied the text and edited this answer..
    – jokerdino
    Aug 4, 2012 at 9:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.