I don't know what I did wrong (it could have been related to rebuilding the Launch Services database), but yesterday after I restarted, multiple processes (like SystemUIServer, NotificationCenter, Alfred, and TextEdit) kept crashing on launch or repeatedly. The Notification Center icon and other icons on the right side of the menu bar kept disappearing. I couldn't make Time Machine backups either. When I tried making another account, it had the same issues, and text in the UI was shown as characters from the LastResort font.
system.log contained repeating messages like this:
Feb 23 17:29:59 Lauris-iMac com.apple.launchd.peruser.501 (com.apple.mdworker.shared.04000000-0000-0000-0000-000000000000): Job appears to have crashed: Segmentation fault: 11 Feb 23 17:30:09 Lauris-iMac.local SystemUIServer: *** Assertion failure in -[MDFileTypeImageCache setImage:forKey:timeToLive:], /SourceCache/SpotlightUI/Spotlight-707.3/menu/Application/MDImageMemoryCache.m:268 Feb 23 17:30:09 Lauris-iMac.local SystemUIServer: image should not be nil Feb 23 17:30:20 Lauris-iMac.local NotificationCenter: registering /System/Library/Fonts/*, /System/Library/Fonts/Base/*, and /Library/Fonts/* locally Feb 23 17:30:21 Lauris-iMac com.apple.launchd.peruser.501 (com.apple.notificationcenterui.agent): Job appears to have crashed: Segmentation fault: 11
I tried deleting
/var/folders/, repairing permissions from the recovery partition, starting up in safe mode, and running
sudo atsutil databases -remove and
sudo mdutil -E /. I think I solved it by just reinstalling OS X, but in case it happens again, does anyone have better suggestions?