Disabling spindump on OSX to prevent slowdown after a crash
Posted 20 May 2008 @ 7pm | Tagged OSX
Update: it’s better to use a spindump script that sleeps, otherwise launchd keeps trying to restart it every ten seconds. Thanks to Steve Ryner for the script. And yes, it’s very simple but here it is :-)
#!/bin/sh
while true
do
sleep 60000
done
Sometimes when things crash on OSX (biggest offenders: Quicktime, and Safari playing flash movies), a program called spindump fires up. This offensive piece of bad engineering thinks its ok to eat 100% of my cpu and thrash my disk just to catalog what happened.
While this is a great idea in theory, and I’m sure it helps Apple engineers debug problems, it does absolutely nothing for me trying to bring my machine into a usable state. Fighting spindump for resources while I try to kill the hanging program is not fun. And many people on online forums seem to think the same. Most of the time I’m barely able to pull up the activity monitor and nuke spindump before it goes off to lala land never to return. Granted things don’t crash often, but when they do there is hell to pay.
Well, we don’t have to submit to this madness anymore. It occurred to me that I could simply rename the spindump executable so that OSX could not find it. So I renamed /usr/sbin/spindump to /usr/sbin/spindump.disabled. I had to wait for my first crash in order to verify that this didn’t break anything, and sure enough I had a quicktime crash just the other night. The system promptly recovered from the crash and did not slow down as previously. Mission accomplished!
Apple is a company built on user experience. But spindump is one of the worst user experience violations in OSX. I know there may not be an easy way around it, but certainly at the very least changing the priority of this process so that it’s not able to eat all system resources may be a step in the right direction. I hope to see an improvement in future versions of the operating system. Until then, spindump is dead to me.



27 Comments