Apple’s Worldwide Developers Conference to kick off June 10 at 10 a.m. PDT with Keynote address

The Keynote will be available to stream on apple.com, the Apple Developer app, the Apple TV app, and the Apple YouTube channel. On-demand playback will be available after the conclusion of the stream.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Massive Mountain Lion memory leak

I will start describing the problem where I first discovered it.


My early 2011 MBP had been asleep, and upon opening and waking it, it was incredibly slow. I opened activity monitor and couldn't believe my eyes.


I have 8 GB of RAM, and all but 8 mb was in use. Around 6 GB was "inactive". I had no applications running besides Activity Monitor.


I opened terminal and ran the purge command After a short wait, total memory usage was back to around 2 GB. Then right before my eyes, over approximately 30 seconds, the "inactive" memory grew until once again, I had about 8 mb of RAM free. This fluctuated a few mb, but nothing significant.


After rebooting, I opened Activity monitor again, to watch ram usage. Usage increased to a little more than 2 GB. I then launched the App Store. Before putting my laptop to sleep earlier, I had been downloading a 10 GB update to Borderlands, but had paused the download, and quit the application before closing the laptop. I hit resume download, and went back to Activity Monitor. Memory usage seemed normal for several seconds, but shortly started increasing rapidly again. I imediately hit "pause download" in the App Store. But ram usage continued rising, so I quit the application. It kept rising, until my full 8 GB was in use.


At this point I took a screenshot:

User uploaded file


The only thing I have left to tell you is that before upgrading to ML, I had previously attempted to download the same update, but hadn't had time to download the full 10 GB, so had cancelled the update. That was in Lion 10.7.4, with 4 GB of RAM, and I had no issues.

MacBook Pro, OS X Mountain Lion (10.8.2)

Posted on Sep 26, 2012 6:17 PM

Reply
Question marked as Best reply

Posted on Sep 26, 2012 6:53 PM

Your screenshot shows nothing abnormal. Having a lot of inactive memory simply means that it's been used and released. If you're curious as to what was using it, you'll have to look at All Processes, not My Processes.

120 replies

Sep 13, 2013 7:16 AM in response to Csound1

I assumed it is obvious. Since you asked, let me do so.


1. Collect a large amount of users' data, who reported the problem.The data should include, but not limited to: the routine applications, the memory allocation to different applications, the applications start and end time, etc.

3. Use some other MAC machines and try to duplicate the problem.

4. If the reason is from some applications, which cause memory leak. Identify why the OS can't prevent such intentionally malicious behaviors.

5. If the reason is that the OS can't release memory properly, fix it!

Sep 13, 2013 7:35 AM in response to dalibocai

dalibocai wrote:


Do a google search and you'll find that so many people observed that when "free memory" is eaten to a certain level (say < 200M), the VM paging becomes crazy. I don't think all those people use the same set of applications. So with a high probability, the OS is the culprit.


Can you supply some attribution, yes or no.

Sep 13, 2013 7:36 AM in response to sergibondarenko

sergibondarenko wrote:


Csound1

Ok, maybe I'm wrong. I will appreciate for your help.

My VM data from "top":

VM: 287G vsize, 1284M framework vsize, 2541445(0) pageins, 325389(0) pageouts. Networks: packets: 4324216/4543M in, 3364271/387M out.




Can you open Activity Monitor and give me 2 figures from it. (Post a screenshot)


Pageouts and VM size


And how much Ram is in your Mac.

Sep 13, 2013 7:43 AM in response to Csound1

Csound1

Software OS X 10.8.4 (12E55)


Hardware Overview:


Model Name: MacBook Pro

Model Identifier: MacBookPro7,1

Processor Name: Intel Core 2 Duo

Processor Speed: 2.4 GHz

Number of Processors: 1

Total Number of Cores: 2

L2 Cache: 3 MB

Memory: 4 GB

Bus Speed: 1.07 GHz

Boot ROM Version: MBP71.0039.B0E

SMC Version (system): 1.62f7

Serial Number (system): WQ*********TM

Hardware UUID: 6325CC93-F67A-5B45-A7FA-BD97B02483FC

Sudden Motion Sensor:

State: Enabled


User uploaded file


<Personal Information Edited by Host>

Sep 13, 2013 8:08 AM in response to Csound1

Csound1


>> You are swapping 30% of your Ram load to disk (since the last reboot)

I saw it already.


>>You are using more than 4GB, get more Ram, you do not have enough.

OS X 10.8 general requirement is 2GB RAM: http://www.apple.com/osx/specs/

I was very comfortable with 4GB on the OS X 10.6. I think those little features the OS X 10.8 brought do not justify such performance downgrade. A 4GB RAM PC with Ubuntu or Windows 7 on board is more effective for proffesional usage, you can open more tabs in a web browser and run more applications than in OS X 10.8, as simple as that.

Look on the Mavericks feature set. Most of them are performance improvements. This is not an accident.


>>Chrome alone is using 0.5GB, ridiculous amount for a browser

Safari is even worse!


What systems performance do you have? If you have a SSD and 8 or 16GB RAM, you only masquerade the performance issues.



Sep 13, 2013 8:32 AM in response to Csound1

The question is not just "Buying more RAM". It's not a problem to buy more RAM.

The question is "Why the OS X has become less efficient with the RAM use?"

When I bought my macbook, I wanted it not because it's a shiny thing but because it was a powerfull computer. And now when I compare it to other notebooks with similar hardware I notice that the OS X 10.8 doesn't meet my expectations.

I hope Apple will correct the performance issues in Mavericks, at least it is already promised.

http://www.apple.com/osx/preview/advanced-technologies.html


User uploaded file

Sep 13, 2013 9:00 AM in response to imclerran

The specific issue in this thread is not going be solved by more RAM. There is probably a single process that's eating available RAM and causing these fairly large pageouts.


If this were me, that is what I would do:


1. Do one Safe Book to clear caches.

2. Then do a normal boot (the first real boot after a safe boot will take longer).

3. Open Activity Monitor and leave it open. Make sure "All Processes" is chosen. Set it for a 2 second update interval.

4. One by open, open the apps suspected of causing this. Don't just open an app, but do the things you normally do in that app and monitor Activity Monitor while you are doing those things.


I think it's still true that every tab in Google Chrome uses a separate process. The good news is that one crash of a process in one tab won't bring down the app. The bad news is that it eats RAM.


I'm constantly using LibreOffice, Word & Excel (because I have to), Pages, iTunes, Safari and Firefox, Mail, Messages, Contacts, Calendar, iPhoto, Preview, GIMP all of the time. I have a mid-2011 13-inch MacBook air with a 4GB of RAM and a 256GB SSD. I typically reboot once a day in the morning. It only takes about 15 seconds so it's no big deal. I do monitor free RAM and pageouts and almost never have any pagouts.


There is something else going on here.


And yes, under normal conditions, having lots of free RAM doesn't do you any good. I want to have all 4GB of my RAM in use. The secret is not to have a lot pageouts.

Sep 13, 2013 9:45 AM in response to sergibondarenko

It isn't a question of memory usage, but app usage. The only people who complain about Mountain Lion VM usage are people who use Photoshop or Chrome. Both Adobe and Google don't support running any other apps. The expectation is that if you are running Chrome, you are only running Chrome. You don't need any other web browsers, e-mail clients, productivity apps, etc. All you need is Google. I don't know what they are doing differently than anyone else, but something is different. I don't use those apps and even though I regularly get very low free RAM (from 10-100 MB), I don't experience any performance problems. Why is that?

Massive Mountain Lion memory leak

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.