#MacOsX : Fix Mountain Lion Slow Shutdown
Ok, actually there are many good reasons to wait a bit of time before send a SIGKILL to processes (like giving them time to write things on disk or finish an upload on the iCloud), however the “slow” shutdown could be annoying, so try this:
sudo launchctl unload /System/Library/LaunchDaemons/com.apple.coreservices.appleevents.plist
sudo defaults write /System/Library/LaunchDaemons/com.apple.coreservices.appleevents ExitTimeOut -int 2
sudo launchctl load /System/Library/LaunchDaemons/com.apple.coreservices.appleevents.plist
This set the shutdown timeout to 2 sec instead of the default value (20).