User: Password:
|
|
Subscribe / Log in / New account

Memory footprint

Memory footprint

Posted Jun 13, 2006 1:28 UTC (Tue) by JoeBuck (subscriber, #2330)
In reply to: Memory footprint by proski
Parent article: Live CDs Part II: Desktop Replacements

To be fair, there isn't really a way to figure out much about memory use from the output of top or htop; they give too confusing a picture.


(Log in to post comments)

Memory footprint

Posted Jun 13, 2006 5:18 UTC (Tue) by jzbiciak (subscriber, #5246) [Link]

Agreed. It's been a long standing complaint "Linux uses all my memory! Where did it go?" going back to probably before I started using Linux, back in 1993.

Most of it does go to disk buffers and shared pages. My own motto is unused memory is wasted memory. The real performance analysis comes from looking at things like vmstat, and whether you have lots of swap or paging traffic.

Available = "Free" (unused) + Cached

Posted Jun 13, 2006 6:30 UTC (Tue) by AnswerGuy (subscriber, #1256) [Link]

I teach my students that the best, simplest approximation of their available memory is the "cached" *plus* "free" (which I translate to "unused" to better explain the meaning in top and the "free" command).

Yes, it's an simplication; but it's a useful one.

Then I teach them to watch the si and so (swap in and swap out) columns under vmstat for at least a couple minutes of sustained three digit values before declaring their system to be "out of memory."

JimD

Available = "Free" (unused) + Cached

Posted Jun 13, 2006 6:57 UTC (Tue) by jwb (guest, #15467) [Link]

Another, more reliable indicator of being truly out of memory is when vmstat takes 5 minutes paging itself in before outputting each line :)

Available = "Free" (unused) + Cached

Posted Jun 13, 2006 19:05 UTC (Tue) by oak (guest, #2786) [Link]

> simplest approximation of their available memory is
> the "cached" *plus* "free"

Why you aren't adding "buffers" too?

Memory footprint

Posted Jun 15, 2006 19:59 UTC (Thu) by landley (guest, #6789) [Link]

If you "cat /proc/meminfo", the first few lines are:

MemTotal: 516228 kB
MemFree: 51432 kB
Buffers: 19104 kB
Cached: 133532 kB
SwapCached: 131464 kB

In my case, I have a total of 516 megabytes of memory (after the kernel's
had its bite, and yes it's a decimal megabytes from binary kilobytes. I
don't care).

Of this 51 megs isn't used for anything, and 131 megs is sitting in swap
(although since I've suspended the system to disk since booting, both are
kinda expected).

About 150 megs (buffers+cached) are used for filesystem cache. That's the
amount that your apps aren't really using, and the number you might want
to subtract from the total when coming up with how much memory is really
in use by your apps.

I'd estimate I easily have over 100 open windows/tabs in my six desktops
at the moment, by the way...

Rob


Copyright © 2018, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds