Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 11 Apr 2002 08:10:44 -0400
From:      Brian T.Schellenberger <bts@babbleon.org>
To:        Patrick Thomas <root@utility.clubscholarship.com>, <freebsd-questions@FreeBSD.ORG>
Subject:   Re: interpreting `top` output...
Message-ID:  <20020411121045.2E80CBA05@i8k.babbleon.org>
In-Reply-To: <20020411011600.C77505-100000@utility.clubscholarship.com>
References:  <20020411011600.C77505-100000@utility.clubscholarship.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thursday 11 April 2002 04:17 am, Patrick Thomas wrote:
| I see this memory summary in `top`:
|
| Mem: 431M Active, 1231M Inact, 277M Wired, 61M Cache, 199M Buf, 12M Free
|
|
| Does the 1231M Inact mean that I can basically fill up another 1.2gigs of
| memory with programs, etc., before I start running out of memory ?

Yes.

| Also, should I be concerned that I only have 12M "Free", or is the fact
| that so much (1231M) is inactive mean that I am not running out for a long
| time ?

The latter.

"Inactive" memory is memory that the O/S could reclaim but it keeps it around 
"just in case" somebody happens to need it again.

Mostly, I speculate, this would be memory that was diskmapped read-only 
(mostly code that has finished running)--so if somebody happens to re-map the 
same disk space (as in re-running the program), it can be used again, thus 
speeding things up quite a bit.  It is certainly quite noticable under 
FreeBSD that if you invoke a large program that pulls in lots of dynamic 
libraries it loads *much* faster the second time, and I believe that the 
concept of "inactive" memory is what causes this to occur.

I'm not sure about the last point, but I do know that inactive memory is 
effectively free and that it tends over time to never go down.  (I run 
xosview all the time, so memory patterns are very visible to me, and the 
pattern is clear: over time, the (acitve+inactive) memory normally only goes 
up--sort of like a fever thermometer--but the active memory takes up a 
variable amount of the (active+inactive) total.  The only exception being 
that if memory gets really tight, and the inactive memory gets all used up, 
then sometimes when memory gets freed again the (active+inactive) amount will 
wind up being lower.  Usually when this happens, some swap winds up getting 
consumed, but I don't believe that this is always the case.

| thanks,
|
| PT
|
|
| To Unsubscribe: send mail to majordomo@FreeBSD.org
| with "unsubscribe freebsd-questions" in the body of the message

-- 
Brian T. Schellenberger . . . . . . .   bts@wnt.sas.com (work)
Brian, the man from Babble-On . . . .   bts@babbleon.org (personal)
                                ME -->  http://www.babbleon.org
http://www.eff.org   <-- GOOD GUYS -->  http://www.programming-freedom.org 

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020411121045.2E80CBA05>