LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 04-25-2005, 01:45 PM   #1
xushi
Senior Member
 
Registered: Jun 2003
Location: UK
Distribution: Gentoo
Posts: 1,288

Rep: Reputation: 45
abnormally high ram usage


I don't get it.. No matter how much ram i stick in, Linux manages to fill it up completly in a matter of minutes. I restart my laptop, start a few apps, and its full again. I have 1 gig of ram, but only ~ 800 enabled (disabled highmem support coz it causes fs corruption on the laptop for some gay reason).

free -m outputs
Code:
root@xushitop:~# free -m
             total       used       free     shared    buffers     cached
Mem:           883        874          8          0          7        698
-/+ buffers/cache:        168        715
Swap:          243          0        243
top outputs
Code:
Mem:    904880k total,   896548k used,     8332k free,     8264k buffers
Swap:   249472k total,        0k used,   249472k free,   716572k cached
ksysguard says (no, i'm an xfce person, but sometimes use kde apps)
that amarok uses 67 megs VmSize (that's 1 thread, there are 10 of them)
gaim uses 43 megs ?!
and so on..

Is there something wrong, or am i too used to windows and this actually is "propper usage of ram" ?
 
Old 04-25-2005, 01:54 PM   #2
neo
Member
 
Registered: Apr 2005
Distribution: FreeBSD
Posts: 61

Rep: Reputation: 15
Linux holds on to memory when you close apps so if you restart it's already in cached memory. As you can see from "free -m" you have 698 MB of cached memory. So in reality you have 883-698 = 185MB of "active memory" the rest is cached or free memory.

It costs nothing to cache it and makes sense just in case you reload the same app. This memory can be released in a microsecond if needed by some other app.

When you are really running out of memory your swap starts to get used. Which almost never happens on my box w/ just 256 MB of memory. Your swap is 0.

Last edited by neo; 04-25-2005 at 01:59 PM.
 
Old 04-25-2005, 02:03 PM   #3
xushi
Senior Member
 
Registered: Jun 2003
Location: UK
Distribution: Gentoo
Posts: 1,288

Original Poster
Rep: Reputation: 45
Ahh, excellent explanation. Thanks
 
Old 04-25-2005, 06:37 PM   #4
shilo
Senior Member
 
Registered: Nov 2002
Location: Stockton, CA
Distribution: Slackware 11 - kernel 2.6.19.1 - Dropline Gnome 2.16.2
Posts: 1,132

Rep: Reputation: 49
neo - great explaination

xushi - I have 1 box with 1G of RAM and found that applying the Con Kolivas patch to the kernel will get you that last bit of RAM without any extra FS headaches. Another tip, maybe it's just me, but it seems that the CK patch is based on 2.11 not 2.11.7. Applying it to 2.6.11.7 got me some weird results.
 
Old 05-20-2005, 12:22 AM   #5
craigevil
Senior Member
 
Registered: Apr 2005
Location: OZ
Distribution: Debian Sid
Posts: 4,733
Blog Entries: 12

Rep: Reputation: 457Reputation: 457Reputation: 457Reputation: 457Reputation: 457
I was wondering the same thing. Thank you for the great explanation.
 
Old 05-21-2005, 09:55 AM   #6
DJOtaku
Member
 
Registered: Oct 2004
Location: USA
Distribution: Fedora 20; Arch; Kubuntu; Debian
Posts: 710

Rep: Reputation: 31
That's great! I was wondering what that was all about. Of course my computers have 128mb, but I would have been very ticked when I finally put Linux on my awesome computer if it appeared to be taking up all the RAM.
 
Old 05-21-2005, 10:25 AM   #7
slackMeUp
Member
 
Registered: Nov 2003
Distribution: Slack-where?
Posts: 654

Rep: Reputation: 30
LOL



It funny that what you thought was a flaw in memory management is really one of the best things about linux (vs windows that is).

Just teasin'
 
Old 05-31-2005, 08:13 AM   #8
redness
Member
 
Registered: Dec 2004
Distribution: Slackware 10
Posts: 40

Rep: Reputation: 16
yeh i was just wondering that too, googled the problem came here, and felt lots better

redness
 
Old 05-31-2005, 08:35 AM   #9
Nobber
Member
 
Registered: Jun 2002
Location: Nova Scotia
Distribution: Debian (home), Kubuntu 7.04 (work)
Posts: 265

Rep: Reputation: 30
xushi's question and neo's concise answer are classic FAQ material, IMHO.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
High memory usage Kapriel Debian 6 07-29-2005 11:01 AM
cpu usage high corbintechboy VectorLinux 2 07-27-2005 08:11 AM
High Mem Usage miketheninja Linux - General 2 11-05-2003 04:26 PM
Memory usage too high glock19 Linux - General 7 06-05-2003 07:05 AM
Ram usage gets high fast lokee Linux - General 2 05-18-2003 10:18 AM


All times are GMT -5. The time now is 11:21 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration