Take the 2-minute tour ×
Ask Different is a question and answer site for power users of Apple hardware and software. It's 100% free, no registration required.

The Dock on my MBP Retina is constantly using 70 - 80% of CPU.

This happens on the two account on the machine, both of which were migrated from my previous Lion MBP.

  • I don't have Parallels installed, which can cause this issue apparently.
  • I've deleted the Dock's plist and restarted it
  • I've rebooted several times

Any ideas on what may be causing this?

Here's a trace on the Dock. I'm not a Mac dev so I find reading that hard.

share|improve this question
    
Out of curiosity, do you have any unusual Desktops/Spaces or Exposé/Mission Control settings? –  Nathan Greenstein Jun 17 '12 at 4:32
    
Not that I'm aware of - although they were imported from my previous mac. Typical - the problem seems to have stopped after 3 days. I'll keep my eye on it. –  dkam Jun 17 '12 at 8:09
    
perhaps your system was indexing itself. Did you migrate from another computer? –  David DelMonte Jun 17 '12 at 8:21
    
@DavidDelMonte He clearly says that all this stuff has been migrated so one can assume that most of his settings were migrated to the new fancy MBP-Retina :) –  Martín Marconcini Jun 17 '12 at 9:20
    
And after a kernel panic(!), we're back to 80% usage. There doesn't appear to be any indexing happening or a TM backup going on. And yes, it is fancy. This display is simply awesome. SSD is great too. And the weight, that's nice. Slim too. Don't forget slim. The Dock though - that's killing me. Killing the battery actually. –  dkam Jun 17 '12 at 11:53
show 3 more comments

7 Answers

up vote 15 down vote accepted

I had this same problem on my new MBP Retina. I do have Parallels installed, but the similar issue caused by Parallels has been fixed in a Parallels update (which I've installed). Moreover, none of the workarounds (e.g. deleting the Windows Applications folder from the Dock) suggested on the Parallels forum fixed the problem for me. I also tried to delete the Dock's plist, restart the process, and restart the computer several times. None of these fixed the problem. The Dock process would go back to using 100% CPU.

Here's what I did to troubleshoot and fix it:

Run this from the command line. This command will list the files the Dock process is accessing or tying to access.

sudo opensnoop -n Dock

I found that Dock was repeatedly trying to access /System/Library/CoreServices/DefaultDesktop.jpg, which is a symbolic link to /Library/Desktop Pictures/Galaxy.jpg. The only problem was that /Library/Desktop Pictures/Galaxy.jpg didn't exist. I'm not sure if the OS came without it at that location or if I deleted it or moved it mistakenly. Regardless, to fix this I repointed the symbolic link to another desktop picture using the following two commands:

sudo rm /System/Library/CoreServices/DefaultDesktop.jpg
sudo ln -s /Library/Desktop\ Pictures/Lion.jpg /System/Library/CoreServices/DefaultDesktop.jpg

It seems that the problem was that Dock was repeatedly trying and failing to access the missing Galaxy.jpg file to set my desktop background via the DefaultDesktop.jpg symbolic link. Once that symbolic link pointed to a real JPG file, Dock's high CPU utilization stopped. On earlier MBPs, DefaultDesktop.jpg was a real JPG file (of a galaxy).

Also this fixed another problem I was having where if I locked my screen and then typed my password to unlock it, my computer would hang while trying to log me in. My hunch is that the Dock was trying to access the same missing file and was hanging on the login screen.

share|improve this answer
    
Fantastic! Thank you very much. I've never come across opensnoop before - I'll check it out further. –  dkam Jun 19 '12 at 22:16
    
Thanks! Ran into this exact same problem. No parallels, tried toasting plist file and restarting Dock to no avail. –  Gabriel Isenberg Jun 24 '12 at 0:40
1  
This is exactly why my lap was burning for the past hour. Thank you (and my future children thank you too). –  psynnott Jun 24 '12 at 19:05
    
OMG thanks so much, that's it, fix worked perfectly. –  n13 Jul 18 '12 at 8:02
add comment

Here is a simpler fix for the non-techies like myself, that worked for me:

  1. Go to Finder and select "Hide Others" from the Finder Menu
  2. Right click (or control-click) on the Desktop
  3. Choose "Change Desktop Background"
  4. Select a new picture (I had to click on a few to get it to change)
  5. Go to Activity Monitor and Force Quit the Dock app
  6. The Dock will restart itself within a few seconds and presto: no more 100% CPU usage

For what it's worth, I took this problem to the Genius Bar at an Apple store and they escalated it to "engineering" at Apple. The answer that came back was that it's Parallel's fault, even though I clearly told them that I wasn't running Parallels. I don't think Apple realizes this is their fault yet. It's pretty simple - all about the background desktop picture!

share|improve this answer
    
I logged it on bugreport.apple.com and they closed it as a duplicate. Apparently you can't view other people's bug reports. –  dkam Jun 26 '12 at 14:41
    
I had to set all backgrounds on all my spaces but it did work. The fix just above worked, but only until restart. –  n13 Jul 18 '12 at 8:35
add comment

One thing to try is to temporarily remove the Dock preference files & see if the CPU badness stops. Try this in Terminal:

cd ~/Library/Preferences
mv com.apple.dock.db com.apple.dock.db_backup
mv com.apple.dock.plist com.apple.dock.plist_backup
killall Dock

Once Dock.app restarts it should open with only the default set of icons. Depending on the presence of installed Apple apps, (iWork, iLife, & etc,) icons for them will be created in the Dock for them, too. You will also have to reset your Dock preferences and add other apps as you see fit.

If you are satisfied with the fix, and the Dock doesn't hammer the CPU, delete the old Dock preference files which caused all the problems:

cd ~/Library/Preferences
rm com.apple.dock.db_backup
rm com.apple.dock.plist_backup

On the other hand, if you wish to restore the original preference files for some reason, do this:

cd ~/Library/Preferences
mv com.apple.dock.db_backup com.apple.dock.db
mv com.apple.dock.plist_backup com.apple.dock.plist
killall Dock

Troubleshooting tip: Alternate between the old & new preference files & restart the Dock to see if the CPU is hammered. If a restore of the original preference files causes the Dock to misbehave, something in one or both of the two files is munged. On the other hand, if the Dock still hammers the CPU with fresh preference files, something else is amiss.

share|improve this answer
    
great suggestion. I'd previously tried just the plist. Unfortunately it didn't seem to fix the issue. I'm thinking a reinstall may be my next attempt. –  dkam Jun 19 '12 at 9:52
add comment

Does this happen with the stock Dock or only after you add your own icons? If you remove the Dock plists and reboot, will this happen again without you touching the dock?

If you don't have anything custom in the dock, the only thing that I can think of (other than some obscure MBP-R bug) is that you may have something in the Download's folder or Apps (or one of the folders that appear in the default Dock) that is causing the Dock hang while reading the filesystem.

A possible fix might be to "empty" the Downloads folder (move the contents to a temporarily location outside the Dock's reach) and fix your Permissions (in case something is amiss inside the Application's folder.

share|improve this answer
add comment

The suggestion about the symbolic link did the trick for me. I had to use this command instead, which contains a slightly different link for the desktop picture folder:

sudo ln -s /Library/Desktop\ Pictures/Lion.jpg /System/Library/CoreServices/DefaultDesktop.jpg
share|improve this answer
    
Thanks. I've updated my answer to include that extra backslash that's needed to escape the space in Desktop Pictures –  crcastle Jun 22 '12 at 21:29
add comment

This happened to me too and freaked me out for a bit, the computer became almost unusable. Fired up the console and all errors were something about "Cannot find default desktop wallpaper". Changed the wallpaper to default from the settings app and everything went back to normal.

IMO this is a bug in Lion and the way it handles wallpapers. Very, very weird.

share|improve this answer
add comment

In addition to the good answers above, as you have migrated from another system, I would suggest the following:

  1. Repair Permissions until all is well.

  2. Make sure you have applied the software update fix that came out late last week for your system.

  3. Send the computer to me, so I can play with it :)

share|improve this answer
    
There were numerous problems with permissions, however it didn't fix this specific problem. –  dkam Jun 20 '12 at 21:43
1  
OK. Are there any console log messages that could give you a clue? David –  David DelMonte Jun 21 '12 at 3:43
add comment

protected by Community Jul 8 '12 at 16:04

Thank you for your interest in this question. Because it has attracted low-quality answers, posting an answer now requires 10 reputation on this site.

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.