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.

Lion - Memory Usage Problems

Why is Lion using all 4GB of RAM running Mail, Safari (2 tabs), and iTunes? Snow Leopard was bad enough at handling memory, eating up every available byte and Lion seems to be arbitrarily using even more RAM. Windows 7 has zero problems handling RAM, there's no reason OS X shouldn't be able handle memory properly.


Can someone explain what Apple is doing here? I'm at a total loss. For users who just need Safari, Mail, and iTunes... I guess this works. But how am I expected to reliably run Logic, Final Cut, or Aperture with OS X using every available resource for Web Surfing, E-mail, and Music. This is totally unacceptable for a multi-million dollar software company greated towards professionals as well as consumers.


The following responses are not acceptable by the way:


  • Buy more RAM - I did that already, it will eat up 2/4/8GB, doesn't matter. Not to mention Apple still sells numerous 2/4GB confirgurations.
  • Buy a newer/more powerful Mac - this is a improper handling of memory issue, not a hardware issue.


I'd really love some insight into this. Thanks for reading.

MacBook Pro, Mac OS X (10.7), 13" (late-2009)

Posted on Jul 21, 2011 5:45 AM

Reply
957 replies

Aug 10, 2011 7:23 AM in response to mightymilk

Everyone, I read in a forum that memory problems can sometimes come from duplicates or corrupted Fonts and therefore I did the following and noticed some minor performance change:


Do the following:


1. In Font Book, do the following

- Select All Font in the left column and choose File > Validate Font

2. Remove fonts that are duplicated.

3. Use application like ONYX or Cocktail to remove all caches and make sure to check the boxes with all caches related to Fonts

4. Restart computer

Aug 10, 2011 7:39 AM in response to Michelasso

Michelasso wrote:

Nope, 3GB. I know, just above the minimum limit. Still it usually gives me more than 1GB of available memory (free + inactive). It pages out if that GB is mostly inactive memory.


Same thing here on iMac 7,1 with 4Gb.

You can force to boot on 32bit mode, even with coreduo, tu see if the problem is there even on 32bit.


And we all must notify Apple Bug reporting team at: http://bugreport.apple.com/

I've already do.

Aug 10, 2011 10:20 AM in response to babowa

I've gone 24 hours with AdBlock removed and that did not make a difference. Safari would still have performance issues (de-graded video playback, spinning beach-balls with tabs loading). Web Content started at about 150 Real memory to over 500 after about 5 hours. This rules out a suggestion by Michelasso and mightymilk.


I'm following another thread with the same machines (and same performance problems) as mine to find out how much free HD space they have. Their thoughts are thinking it might be the ATI video driver. I want to this rule out (or in) as the main performance issue suggested by John Kitchen and you. Flipping out my iMac's HD to a larger one will be a last resort.


I'm seeing something common in alot of the Lion threads with issues (after ruling out indexing) - very slow performance after being on for a while and hot Macs.

Aug 10, 2011 10:55 AM in response to Atomic Al

Atomic Al wrote:


I've gone 24 hours with AdBlock removed and that did not make a difference. Safari would still have performance issues (de-graded video playback, spinning beach-balls with tabs loading). Web Content started at about 150 Real memory to over 500 after about 5 hours. This rules out a suggestion by Michelasso and mightymilk.


I'm following another thread with the same machines (and same performance problems) as mine to find out how much free HD space they have. Their thoughts are thinking it might be the ATI video driver. I want to this rule out (or in) as the main performance issue suggested by John Kitchen and you. Flipping out my iMac's HD to a larger one will be a last resort.


I'm seeing something common in alot of the Lion threads with issues (after ruling out indexing) - very slow performance after being on for a while and hot Macs.


Just to be clear, I was saying the memory consumption rate should go down if you disable Extensions. Over time though, I'm experiencing high memory usage just like you, it just happens at a slower rate with AdBlock disabled.


With AdBlock enabled I was almost doubling my RAM usage in any given amount of time. It's certainly not a solution, but helped ease the burden.

Aug 10, 2011 10:56 AM in response to stamatgeorge

stamatgeorge wrote:


Everyone, I read in a forum that memory problems can sometimes come from duplicates or corrupted Fonts and therefore I did the following and noticed some minor performance change:


Do the following:


1. In Font Book, do the following

- Select All Font in the left column and choose File > Validate Font

2. Remove fonts that are duplicated.

3. Use application like ONYX or Cocktail to remove all caches and make sure to check the boxes with all caches related to Fonts

4. Restart computer

I tried this, not noticing any performance differences but thanks for your contribution.

Aug 10, 2011 11:17 AM in response to jesslorenzo

I am having the same problem as everyone. After a few hours of running, machine starts swapping and slows down considerably, of course.


I tried not using Safari and Mail, but problem persisted, although much less swap was used in this case.


Finally, I have been running in 32-bit mode for last 4 hours. Here is what Activity Montor looks like - as you can see, I'm back to u sing swap.


User uploaded file

Aug 10, 2011 11:39 AM in response to mightymilk

Ah yes, yet another "purge" app. That's four or five purging apps since the release of Lion.


Another thing that may help some whose Mac is swapping would be to uncheck "Put Hard disks to Sleep When Possible" - System Preferences>Energy Saver. A sleeping disk accessed by memory management might get the beachball bouncing.


Message was edited by: urabus

Aug 11, 2011 1:46 AM in response to urabus

urabus wrote:


Ah yes, yet another "purge" app. That's four or five purging apps since the release of Lion.


That says more about these memory/fan/temperature/slowness issues than anything else.


We can fool around with safari extensions, fonts, disk cleanups, memory, etc., but all of those activities are just instances of tweaking around the edges. The bottom line is that Lion is bloatware.


... and probably bloatware with bad memory management.

.

Aug 11, 2011 2:04 AM in response to John Kitchen

John Kitchen wrote:


The MBA probably gets away with 2GB since it has an SSD. No doubt it often pages like crazy, but the speed of the SSD allows it to do so with an order of magnitude less impact than if it used an HDD.

Oh well, just to be sure I decided to take off the 1GB memory bank from my MB, leaving 2GB. Restarting Lion with the same previous session, which is Mail, Safari and all little apps like System Preference, GlimmerBlocker, iStat Menus etc, it was performing pretty well in terms of memory, leaving 6-700MB free.


Then I decided to do two tests. i disabled the virtual memory and loaded Chrome. It didn't crash, Chrome was usable but it took ages, I suspect freeing the Inactive memory. Basically the OS kind of "froze" for a minute like when we use the purge command. Funny how Safari's WebProcess reduced in size from 350MB to something like 140MB and Chrome was actually taking much more memory.


Once Chrome complitely loaded with its dozen tabs I could switch from Chrome to Safari or even Mission Control without much pain. So I enabled the virtual memory and Lion paged out something like 700MB.


Lets' say that for regular day to day operations, email, web browsing and maybe Office (Word takes 100MB or so), 2GB should be enough. If then it starts swapping the SSD obviously helps, but still it is not a good replacement for more RAM. Especially the first Apple SSDs that are pretty slow.


Interesting enough, since I couldn't know which one was the 1GB memory bank, I first run took off the 2GB one. Lion did work with 1GB RAM. But obviously it started paging as soon as I loaded Safari, taking over the OS. I don't believe any SSD would help much in such a case. It was all disk activity.

Aug 11, 2011 2:50 AM in response to Atomic Al

Atomic Al wrote:


I've gone 24 hours with AdBlock removed and that did not make a difference. Safari would still have performance issues (de-graded video playback, spinning beach-balls with tabs loading). Web Content started at about 150 Real memory to over 500 after about 5 hours. This rules out a suggestion by Michelasso and mightymilk.

Don't get me wrong, 500MB usage for Web Content is fine with me. As it happens to mightymilk with AdBlock enabled I get more than twice of it.


Still, like others suggested, I also did run Onyx to clean out all caches and rebuild some system resources. I have a slow boot and shutdown as well and somehow that helped. After that at least the 2 directories


- /Library/Caches

- $HOME/Library/Caches


(where $HOME is obviously your home folder "/Users/<your ID>", if you don't know about UNIX shell) should be empty. If they aren't manually erase all filles and suboflders in that. From Terminal:


sudo rm -rf /Library/Caches/* $HOME/Library/Caches/*


You will be prompted for the administrator password.


I also uninstalled Paralles (it doesn't work fine with Lion anyway) to remove the virtual netowrk interfaces. My system gets slow on boot when loading the ethernet and wifi interfaces (checked booting in verbose mode, CMD-V at the boot time) so I thought that could help.


Another thing to check are the "Internet Plugins". You find them in


- /Library/Internet\ Plug-Ins/

- $HOME/Library/Internet\ Plug-Ins/


I moved to another directory all the ones that I didn't know and that were older than 1 June 2011. In most cases if needed the web browser should ask to reinstall them.


Also I thought I had the last session messing up when logging in. So I manually cleaned the directory


$HOME/Library/Saved\ Application\ State/


which is where the last sessions for all applications are saved.


Last but not least, months ago in SL Safari was behaving badly. I discovered that it was due to the history that still being set to keep only the last month links, went back to 2 years before using hundreds of megabytes. Since from the web interface it didn't work I had to clean it removing all files in


- /Library/Caches/Metadata/Safari/History


But I see now that it will be empty once you remove all caches in the previous step.


Before you get scared thinking why my system is so messed up just remind that it has been constantly upgraded from OS X Tiger. I've found stuff that was 4-5 years old on it. And the last method to upgrade to Lion from SL I don't think did help at all. Now, boot time apart, it feels pretty smooth. Even faster than SL in some cases. Apart when I QuickLook some videos, the frame rate drops. But loading them with VLC they play fine.

Aug 12, 2011 2:21 AM in response to GlennW

GlennW wrote:


Based on this Activity Monitor snapshot your system is not paging. 4.1 MB of swap is nothing. 113 KB of total pageouts are also nothing. Your system is paging if you've got hundreds of MB or more of swap allocated, and are consistently showing a pageout rate of at least a few hundred KB/sec.

That's true, I thought the same. Still I wonder why the OS had the urge to page out some data still having a large amount of RAM available. But at this point as Atomic Al I'll just wait for the next Lion update to see if anything changes. Hopefully it will be in the changelog.

Lion - Memory Usage Problems

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