Mac OS X Memory Usage

From Wurst-Wasser.net
Jump to: navigation, search

This article describes how to interpret Mac OS X's memory display in Activity Monitor.

The "Problem"

Although applications are terminated, memory doen't get freed...or so it seems...

  1. Memory usage when maaany applications are running:
    MacOSXMemoryFoo01.png
    Free: 1.07GB
    Wired: 1.39GB
    Active: 4.37GB
    Inactive: 1.16GB
    Used: 6.92GB
  2. Memory usage after maaany applications have been terminated:
    MacOSXMemoryFoo02.png
    Free: 2.30GB
    Wired:139GB
    Active: 3.48GB
    Inactive: 856M.6B
    Used: 5.69GB
    Although applications are terminated, memory doen't get freed...
  3. Memory usage after purge:
    MacOSXMemoryFoo03.png
    deep-thought:myScripts heiko$ purge
    deep-thought:myScripts heiko$


    Free: 3.19GB
    Wired: 1.38GB
    Active:3.02GB
    Inactive: 419.1MB
    Used: 4.80GB

The "Why"

When memory is freed, it doesn't immediately appears as "free", instead its "inactive" and is used as kind of cache in case the same data will be reused soon (i.e. re-launching the terminated apps). purge "frees" this inactive memory immediately, but this might be contra-productive.