Restarting the Dock in OS X

The problem is that when your Dock freezes in OS X it can be difficult to get to programs to restart it or anything pretty much. Luckily, when mine froze today I had a Term open and this is how I restarted it without having to power down my damn computer.


jstump@Joseph-Stumps-Computer
jstump$ ps auxw | grep Dock
jstump  3231   0.0  0.5   169272   4204  ??  S     9:48AM
 0:04.75 /System/Library/CoreServices/Dock.app/Contents/MacOS/Dock -psn_0
jstump  6868   0.0  0.0    18644     92 std  R+   11:45AM
0:00.00 grep Dock
jstump@Joseph-Stumps-Computer
jstump$ kill -HUP 3231

The second field in ps‘s output is the pid for that process (Process ID). Using kill we can restart the Dock without crashing everything. You’ll see your Dock disappear for a second and reappear in working form a second later.

3 thoughts on “Restarting the Dock in OS X

  1. Instead of messing around with ps, you can just do:
    $ killa -HUP `pidof Dock`

    Or, better yet:
    $ killall -HUP Dock

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.