Home ยป HOWTO: Stop Random OSX Hangs

with 2 comments

My main machine is a MacBook running Leopard. Its hard drive is always verging on full, especially since I got the Rebel and have been shooting gigs and gigs of RAW fotos.

A few months ago (shamefully) it started randomly hanging. It’s a testament to my ability to learn to live with pain that I mostly just ignored the problems.

Then it started happening when I was listening to music.

Then it started happening when I was watching films.

Then it started happening in the middle of poker games.

This last was unacceptable. I’ll take a ten second second chunk out during some dumb movie, but a minute-long hang (they were slowly getting worse) during a poker hand that times out and folds after 30 seconds is actually losing me money.

It changed my play a couple of times. I noticed that once a hang started I would usually still have access to my poker client for a while, but in the interests of not timing out I would go all-in and move the game flow logic off my client and onto the server.

This got me to thinking: why did I still have access to the poker software, but nothing else? Usually it lasted until the end of the hand when the history is written to the hard drive.

I realized that basically everything that I lost during these hangs — I usually have iTunes, Safari, and Lightroom open — is constantly accessing the disk, but Full Tilt only did so at the end of a hand. Similarly I could keep editing stuff in VI, but when I ESC-:-w’d I’d lose control.

Which, because I have good tech intuition, reminded me of Mike’s post about Spotlight indexing removable drives.

The solution to my problem turned out to be identical:

sudo mdutil -a -i off

Turn off Spotlight disk indexing! It sux!

Written by Jack

February 21st, 2010 at 9:55 pm

Posted in Uncategorized

Tagged with ,

2 Responses to 'HOWTO: Stop Random OSX Hangs'

Subscribe to comments with RSS or TrackBack to 'HOWTO: Stop Random OSX Hangs'.

  1. You should get MenuMeters so you can tell when your disk is the bottleneck.
    http://www.ragingmenace.com/software/menumeters/

    Because disk activity lights are for neeerds with PCs.

    Mike Lin

    21 Feb 10 at 10:14 pm

  2. [...] the Android emulator takes effing forever to start. At first I thought my Spotlight hangs were back. But, no, Usenet sez, no — the pithiest answer: continue waiting [...]

Leave a Reply

Notify me of followup comments via e-mail. You can also subscribe without commenting.