A possible solution for system hang on Safari launch – Mac OS X Hints

Evidently Safari may appear to hang, and cause slow system response if the Safari Cache files have been corrupted.

— Snip —
Recently, any time I tried to run Safari on 10.6 caused all apps and the Finder to hang with the spinning beach ball. Force-quitting Safari stopped the problem, but it would occur again on the next launch. Googling around, I saw many folks reporting similar problems, but no solutions.

The /var/log/system.log file shows something like this when this hang occurs:

Nov 13 09:51:16 bvmbook Safari[394]: INSERT-HANG-DETECTED: Tx time:46.498542, # of Inserts: 0, # of bytes written: 0, Did shrink: YES

Sounds like a database problem. So I looked at which database-type files were opened by Safari, with this in Terminal:

(View the rest of the article at Mac OS X Hints.)