Lately I have been experiencing slow shutdowns on my Late 2009 Unibody MacBook.
Sometimes it even took my laptop over 30 seconds to shutdown, which is ridiculous. It should usually take like 2 to 5 seconds.
I have been searching the hell out of Google, until I found an Apple Discussions post mentioning a few terminal commands, that seemed to fix the problem.
Open up your terminal, by going to Applications > Utilities > Terminal. Enter the following magic words:
sudo chown root:admin /
sudo kextcache -system-prelinked-kernel
sudo kextcache -system-caches
It should ask for your user password. Make sure you are logged in using a local administrator account, or else it will not work.
I am not responsible if this breaks your laptop. It shouldn’t break it, at least mine is still working.