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

Mar 23, 2015 12:45 AM in response to Dave™

Sorry to say no, it does not work on my machine. I followed all the steps and it improved the the situation a little bit.

I was hoping that the security fix by last friday might help, but it did not.


Still the same: When writing an email the fans start spinning (like with heavy rendering work) and CPU- and memory-usage are moving up. Just by writing a 2-line-email! The fans keep spinning even if you leave the computer by itself.


Some other posting said that there are problems concerning mail and google-accounts resulting in memory-usage. There was a work-around mentioned, but I could not find the switches in Yosemite. Has anyone more information on that? Hope I find that post again.

Regards

Mar 23, 2015 12:53 AM in response to monostone

monostone wrote:


Some other posting said that there are problems concerning mail and google-accounts resulting in memory-usage. There was a work-around mentioned, but I could not find the switches in Yosemite.

Delete your Gmail account from Apple Mail and re-establish it from scratch. If you have a POP account and do not leave messages on the server, make sure to archive those message before you delete the account. Most users find IMAP accounts to better suit their needs, especially if multiple computers / iDevices are being used.

Mar 23, 2015 1:44 AM in response to MadMacs0

My Gmail-Account is IMAP. We tried that before, but I'll give it another try. I deleted GMAIL and made it new.

What I found out meanwhile:


It is not happening everytime I am writing an email.

It always happens the moment I open a template. Mail uses 120% CPU, my User-Account-CPU-Usage goes up from just a few percents to 25% CPU-load and the fans are spinning heavily.


I created an new account with nothing installed on. Only one account with me.com. No google-account.

Same behaviour. Mail, opening a template and CPU-Usage and fans go up.

Maybe I should start a new post on that.

Mar 25, 2015 1:46 AM in response to Piergigi

I think, that most of the memory-problems were due to Mail 8.2 using (own) templates.

I followed the advice, even if it took two people to convince me (you and Linc Davis).

The workaround seems to work.

What I did:


1.

I copied all my *.mailstationary-files from

~/Library/Containers/com.apple.mail/Data/Library/Application Support/Mail/Stationery/Apple/Contents/Resources/Custom/Contents/Resources

to desktop.

I deleted all my templates within Mail: create new mail - open templates - open favorites - delete my templates one by one.

The user-folder ~/Library ..../Resources now is empty.


Close Mail.


2.

I created a folder

/Library/Application Support/Apple/Mail/Stationery/Apple/Contents/Resources/MyTemplates/Contents/Resources

and copied my *.mailstationary-templates into that folder.

Thank you both.

Mar 25, 2015 2:11 PM in response to Luis_Mercado

I think my issue is a bit unrelated, since my cpu performance issue is triggered by a startech/display link USB3toDVI video adapter, but, I thought I would cross post my response from http://plugable.com/2015/03/16/displaylink-releases-updated-mac-driver-v2-4-beta -1, in case other people found this as well. Wish I could search the posts in this thread.


dwight s.

--

I recently (yesterday, march 24, 2015) upgraded from mavericks to yosemite, and have noticed substantial lag/delay, bringing up mission control (aka expose), when hitting the F3 key, when my displaylink usb3 hdmi adapter is connected. I'm on a 2012 mac mini, 16gb ram, 240gb ssd, intel hd4000 w/ 1GB, intel core i5.


For example, it can take 2-3 seconds for OSX to respond to the F3 key press. Disconnecting the USB3 video adapter and performance goes back to normal. I tried both the 2.3 driver and the 2.4b1 one as well, with similar behavior. Watching "top" in a terminal shell shows WindowServer (the UI process) taking upwards of 200% cpu utilization. Disconnecting the adapter, without rebooting, returns to responsiveness, with only a slight hestitation in redrawing the display, with WindowServer process taking 50-60% cpu instead.


While the USB display adapter was slower on mavericks than hdmi/display port connected, it was much quicker that it has been with yosemite. I'll keep an eye out for driver updates, to see if they release any more improvements.

Mar 26, 2015 12:58 PM in response to Luis_Mercado

This resolved the high memory usage on my 2008 Mac Pro. No amount of fiddling or rebooting seemed to clear things up until I did the SMC and PRAM reset as laid out in the recipe. I have 5GB RAM on the box and OS X with nothing running was hitting 2.6GB of RAM used. I have been upgrading OS X on this box since I got it so who knows what kind of sludge was floating around in the PRAM. I was actually thinking of upgrading the RAM to put a bandaid on the problem but after this it dropped down to a more reasonable 1.6GB of use. Much better. We'll see if the solution sticks.

Mar 26, 2015 4:04 PM in response to cblouch

cblouch wrote:


I have 5GB RAM on the box and OS X with nothing running was hitting 2.6GB of RAM used. I have been upgrading OS X on this box since I got it so who knows what kind of sludge was floating around in the PRAM. I was actually thinking of upgrading the RAM to put a bandaid on the problem but after this it dropped down to a more reasonable 1.6GB of use.

Just a reminder, in case you didn't get a chance to read it elsewhere in this way to long discussion. You shouldn't be paying attention to how much RAM is in use, since Apple changed the way it does memory management when Mavericks was introduced. Admittedly, 2.6GB with nothing running wasn't right, but OS X will now always attempt to keep RAM as full as possible to avoid having to access your drive for frequently used data. The best way to judge whether you have enough installed is top open Activity Monitor to the Memory tab and watch the MEMORY PRESSURE graph at the bottom. If it stays Green most of the time, you should be fine with what you have. Yellow indicates you should continue to watch closely and if it's Red most of the time then time to invest. Additional details can be found at How to use Activity Monitor.

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.