Where is my memory :(
Hello I am running a linux maching on a PC which has 2 GB of RAM Installed.
I run out of memory most of the time so I try to understand where memory goes. Code:
caracus:/home/apa # free -m Code:
top - 15:28:52 up 3 days, 7:22, 9 users, load average: 4.73, 5.60, 6.36 Perhaps then I could be able to blame something that consumes my memory. Best REgards Alex |
well.. Xorg and Firefox. Make sure your system is all up to date and restart X, and watch it.
Also, if you don't know, http://www.linuxatemyram.com/ |
Thanks for the web site :)
|
That's a good site, I will link to it, because a lot of people ask this question.
|
However I do think you have a problem since you're using almost 2GB of swap. Run vmstat 10 and watch the 'so' and 'si' columns - if there are a lot above 0 then you're actively swapping and you definitely have a problem.
|
I did a google search for +xorg +"memory leak" and of course there are a ton of hits and I don't know how to evaluate which are relevant. The one that looked most relevant was
http://forums.opensuse.org/get-help-...os-11-0-a.html Quote:
Those stats seem to indicate MATLAB, java, konqueror, plasma-desktop and maybe others are tying down a lot of memory while relatively idle. The swap partition is nearly full, so the kernel is forced to leave anonymous pages of idle tasks in physical ram while either dropping pages of active .so's or even calling the "out of memory killer". So if those stats indicate all valid use of memory (not leaks) then you need a larger swap partition. Even with that, you would have terrible performance each time you switch to a previously idled task and even worse if too many of those tasks are trying to be active at once. You might also need more physical ram. If it is a memory leak, the most likely problem is Xorg. But I don't have good advice on how to figure out whether there is a memory leak in Xorg. Quote:
So the answer is not the usual "everything is OK, you just misunderstood the stats". The answer is one of: 1) There is a memory leak that should be found and fixed. 2) You need more swap space 3) You need both more swap space and more physical ram. |
To find out if Xorg is leaking, leave it on alone (close firefox and the rest) for a while and check top once in a while to see if RAM usage goes up. If it keeps going up, it is a leak.
I don't see any reason to suspect a leak in Xorg, it could be just a lot of memory intensive processes running, close them all and see if it reduces back to normal. |
Quote:
Code:
2850 root 20 0 73280 58m 3720 S 2 12.5 1:09.60 X Code:
jan@Beryllium:~$ cat /proc/meminfo |
Quote:
Quote:
I don't know enough about Xorg. I don't know enough about all the other idle windows in the OP's system (that weren't mentioned in top). So I'm not trying to say those values indicate a leak, just that they make one suspect a leak. |
Memory leaks are hard to diagnose and hard to fix, so if you know a better way, say so. Otherwise, I would close all processes except for Xorg and see if the usage goes down, if it does, then it was just those processes. You can also try using a program that you know doesn't leak but uses Xorg.
When I was running Xfce I had exactly that happen, and no matter what I did the RAM usage went up with time (characteristic of a leak). It didn't matter if I left it alone or did something, the leak was still there. |
Quote:
You are running some version of KDE 4? Well, that'll probably be the problem then. </attitude> Looking at your numbers, there are several noteworthy features:
You are probably running the version of KDE that came with SUSE out of the box; if so, ensure that you do not have random repositories enabled and try an upgrade to factory if you dare. If you have any conflicting repos enabled currently, sort that problem out and see where that gets you. (Hmm, that last link seems to be a thread started by someone called, on that forum, alaios; that repo list looks a bit longer than desirable, but with nothing crazy in it - not the full 'I've used one click install a lot' madness). Alternatively, try a different GUI; do you still have the same problem? |
All times are GMT -5. The time now is 11:37 PM. |