Skip navigation

Where is my memory?

1596 Views 7 Replies Latest reply: Feb 23, 2011 7:20 PM by Kappy RSS
marianmi Level 1 Level 1 (5 points)
Currently Being Moderated
Feb 22, 2011 8:22 PM
I have disabled the VM, for performance reasons (I have 4GB of RAM). As long as my RAM does not fill-up, everything works nice. Thus, I am looking from time to time to the memory usage, and kill or restart some of the apps that end up taking too much memory.

The problem that I want to ask about is the fact that the sum of the *Real Mem* column does not match the Used number in Activity Monitor. For example, the sum of the processes displayed is something like 2GB, but the actually used memory is 3.2GB. In cases such as these, I cannot find any app going crazy on memory and kill it.

Any idea what is taking up this unreported memory?
Macbook Pro, Mac OS X (10.6.6), C2D
  • Kappy Level 10 Level 10 (221,010 points)
    Currently Being Moderated
    Feb 22, 2011 8:51 PM (in response to marianmi)
    About OS X Memory Management and Usage

    Reading system memory usage in Activity Monitor
    Memory Management in Mac OS X
    Performance Guidelines- Memory Management in Mac OS X
    A detailed look at memory usage in OS X

    Understanding top output in the Terminal

    The amount of available RAM for applications is the sum of Free RAM and Inactive RAM. This will change as applications are opened and closed or change from active to inactive status. The Swap figure represents an estimate of the total amount of swap space required for VM if used, but does not necessarily indicate the actual size of the existing swap file. If you are really in need of more RAM that would be indicated by how frequently the system uses VM. If you open the Terminal and run the top command at the prompt you will find information reported on Pageins () and Pageouts (). Pageouts () is the important figure. If the value in the parentheses is 0 (zero) then OS X is not making instantaneous use of VM which means you have adequate physical RAM for the system with the applications you have loaded. If the figure in parentheses is running positive and your hard drive is constantly being used (thrashing) then you need more physical RAM.
    Mac Pro 2.66 Ghz; MBP Unibody; MBP C2D 2.33 Ghz; 11" MBA, Mac OS X (10.6.5), iMac C2D 17"; MB 2.0 Ghz; iPad 32G; 80GB iPod Video; iPod Touch; iPod Nano 2GB
  • thomas_r. Level 7 Level 7 (26,935 points)
    Currently Being Moderated
    Feb 23, 2011 4:01 AM (in response to marianmi)
    I have disabled the VM

    Why would you do that? My Mac has 4 GB of RAM, and even when I seriously overload it, it's still quite snappy. (We're talking about running the following apps, which I actually do from time to time: Mail, Safari, Firefox, Photoshop Elements, Intaglio, Aperture, Textwrangler, Transmit, MAMP, iTunes and a handful of small background apps like GeekTool and Quicksilver.)

    Basically, you have made an unsupported modification by removing something integral to your Mac. There's a reason there's no way to turn it off except via hacks. If you were having performance issues, you need to address that in a different way... this ain't it! Turn VM back on, then check out the [Mac OS X speed FAQ|].
    17" MacBook Pro, Mac OS X (10.6.6), iPhone 4
  • Kappy Level 10 Level 10 (221,010 points)
    Currently Being Moderated
    Feb 23, 2011 10:01 AM (in response to marianmi)
    There are hundreds of processes that are not listed in Activity Monitor. You can only hope to see all of them from the Terminal application using 'top.' Unfortunately trying to add up memory usage is nearly an impossible task because the information is dynamic, not static.

    Activity Monitor provides you with basic information on the amount of memory presently allocated to each of the four categories - Wired, Active, Inactive, and Free. AM re-counts that information once every 2 seconds (normally, unless you change the interval.) You are chasing after an ever changing number by adding up an incomplete set of data. Why?

    It's a bad idea to disable the VM system. The page outs reported most likely page to nowhere since you have no swap file. This will just slow down the system as that information is not longer available to be paged in when needed.

    Is there some particular reason why you are undertaking this exercise?
    Mac Pro 2.66 Ghz; MBP Unibody; MBP C2D 2.33 Ghz; 11" MBA, Mac OS X (10.6.5), iMac C2D 17"; MB 2.0 Ghz; iPad 32G; 80GB iPod Video; iPod Touch; iPod Nano 2GB
  • BobHarris Level 6 Level 6 (12,505 points)
    Currently Being Moderated
    Feb 23, 2011 4:54 PM (in response to marianmi)
    From Activity Monitor Help
    Used memory is the sum of wired, active, and inactive memory. If the system requires memory it takes free memory before used memory.

    However, Real Mem will contain some Shared memory, which means that several processes may be sharing the same page of memory. Libraries and Frameworks code are all shared amoung all the processes using those libraries or frameworks. So in theory some Real Mem will be counted multiple times in each app using that shared memory.
    MacBook/10.6.6, iMac/i7/10.6.6 w/Magic Trackpad, Mac mini/10.5.6, iPod Touch(4thGen)/32GB/4.2.1, iBook/G4, MacBook Pro/Core2Duo, iMac/Core2Duo
  • Kappy Level 10 Level 10 (221,010 points)
    Currently Being Moderated
    Feb 23, 2011 7:20 PM (in response to marianmi)
    Well, the swap is a major part of the VM system since a swap file and the hard drive form the basis for virtual memory. Disabling it is a hack because it is not disabled normally, and it requires your intervention to disable it. OS X does not provide the user with a means for disabling it unless you make an alteration to one of the system files that loads during startup.

    In reality you are wasting your time on a non-issue by turning something that is nothing into something you believe is important. Re-enable the swap. Your memory is fine. You've provided no evidence there is even a problem.
    Mac Pro 2.66 Ghz; MBP Unibody; MBP C2D 2.33 Ghz; 11" MBA, Mac OS X (10.6.5), iMac C2D 17"; MB 2.0 Ghz; iPad 32G; 80GB iPod Video; iPod Touch; iPod Nano 2GB


More Like This

  • Retrieving data ...

Bookmarked By (0)


  • This solved my question - 10 points
  • This helped me - 5 points
This site contains user submitted content, comments and opinions and is for informational purposes only. Apple disclaims any and all liability for the acts, omissions and conduct of any third parties in connection with or related to your use of the site. All postings and use of the content on this site are subject to the Apple Support Communities Terms of Use.