You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

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

Guide: How to solve Yosemite memory leaks and CPU usage

I post this hoping to help those users who, like me, are experiencing high CPU usage and massive memory leaking with OS X core services and apps, leading to slow performance and battery drain.


I've tried everything mentioned, but found the right combination of steps to follow. I've tried this with seven different Apple computers, including mine, and has worked well so far. I applied this method yesterday to give these process a 24 hour window to fail again, so far everything good.


First step: disconnect any external or secondary monitors, if any is present. The video memory allocation leak can also happen if you have a system with an integrated card, like Intel, with no external monitors attached.


Second step: Shut down your machine and enter Safe Mode (press shift once you turn on your computer again, more info below). Once you're there, fix your disk permissions.


Guide of how to access Safe Mode: OS X: What is Safe Boot, Safe Mode?


Third step: From Safe Mode turn off your machine again and reset your System Management Controller (SMC). There are different methods, depending on machine, to do this. To know what method applies to yours read the following guide.


Intel-based Macs: Resetting the System Management Controller (SMC)


Fourth step: Once your machine completes a full boot after resetting the SMC turn it off again and reset your PRAM (THIS IS THE MOST IMPORTANT STEP, BUT THE PREVIOUS ONES ARE ESSENTIAL FOR THIS ONE TO WORK). The PRAM stores small bits of data that indicate our Apple computer how to interact with the devices connected to it, including monitors and video cards. It also affects software.


To reset it you should hold the OPTION, COMMAND, P and R keys in your keyboard immediately after turning on your machine again.You'll hear the start up chime, continue pressing the keys until the machine boots and the chime starts A SECOND TIME, then release. IF YOUR YOSEMITE INSTALLATION LOCKS UP AT A BLACK SCREEN AFTER THIS, DONT PANIC! It's normal, just turn off your computer and let it boot again.


More info about PRAM: OS X Mavericks: Reset your computer’s PRAM


Voila, reconnect your external displays and enjoy your system.


Message was edited by: Luis_Mercado

MacBook Air, OS X Yosemite (10.10)

Posted on Oct 23, 2014 10:45 AM

Reply
557 replies

Dec 13, 2014 3:38 AM in response to Csound1

I'll reply when swapping starts and we can talk some more about memory not being used on anything.


I'm currently developing a super smal rest api (4-5 small resources) in netbeans with jersey and a vagrant machine running on 512mb of "ram" with a mysql installed.


Not a 2GB XCode iPhone development footprint, not an Android Studio with emulator running, but a super small development footprint on memory.

Dec 13, 2014 3:40 AM in response to frankydt

frankydt wrote:


I'll reply when swapping starts and we can talk some more about memory not being used on anything.


I'm currently developing a super smal rest api (4-5 small resources) in netbeans with jersey and a vagrant machine running on 512mb of "ram" with a mysql installed.


Not a 2GB XCode iPhone development footprint, not an Android Studio with emulator running, but a super small development footprint on memory.

Do you know when swapping starts?


How is swapping indicated?

Dec 13, 2014 3:49 AM in response to Csound1

Swap used grows to 1.7 GB in activity monitor. I haven't notice when it exactly starts. One indication is netbeans or chrome lagging or delaying when I type or select a tab. that "slowness" or "temporarily blocking" is usually a good indicator that the memory for the tab or the action or one of its elements is being read from disk, usually. So when that happens, I look at Activity Monitor. This is every day a few times a day. I suspected a memory leak on java, no doubt my first choice, but it kept everything at ~200-~600mb or so that is what top (command) shows.


Don't know what else to say, I'm a total mac fan, but my split screen, my missing usb-keyboard keys, and the XXXXX that I say is swapping and you say is just my imaginations, is really annoying.


Best wishes for the holidays

Dec 13, 2014 7:21 AM in response to Luis_Mercado

I knew those tips but I'd like to ask you 2 more questions:

Is there any differences when computer is in file vault?


Does a single corrupted mail may cause this CPU problem and massive memory leaks?

It is the first time I had a kernel panic ( memory allocation for mail going to more than 100% with all the system blocked) I delete the mail but in Web mail I download the zipped files included. When I tried to open one of the unzipped PDF files the same problem occurred. So there I am not daring to try to open those files again (they are from my electricity provider!!)


Thanks for your answers if any. I'd like to know if it is possible.


Constance

Dec 13, 2014 8:35 AM in response to CathyLapin

The difference with file vault is that the HW support for encryption of disk operations is used. So regarding memory: no.


The Mail issue is likely something else. There are other threads which talk about Mail eating up memory. This seems to be a bug with Mail itself (or it forces some other bug within Yosemite). Some people claimed the solution described here have helped. Others don't.

Dec 16, 2014 1:07 AM in response to frankydt

I'm using Yosemite on an older iMac (w/ 4GB RAM and still well with in the system requirement range) and I initially had no issues with Yosemite after first installing, and never had any issues with Mavericks. Over time the UI seemed to bog down especially when waking after the machine had been in operation a while. Upon waking there seemed to be a lot of activity and I was getting more swap and compression (in addition to the Windowserver issues mentioned). I tried the process detailed at the beginning of this thread, but it didn't help me either. I shut off transparency (although nice, not essential) and that seemed to make things somewhat better, but over time there still seemed to be swap/compression issues just not as intense as previously. Version 10.10.1 really didn't help the situation any.


What really seemed to make the difference to getting back to Mavericks performance for me was the Safari update 8.0.2. Now there is very little swapping and compression in normal operations, and I see very little of the UI lag I was experiencing with Yosemite. I usually have Mail, Safari, and many of the other standard apps open at the same time and for the past few days they've all been working like they used to under Mavericks.


Not a solution, just an observation.😐

Guide: How to solve Yosemite memory leaks and CPU usage

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