An AppleJack a Day
In the comments to my near-desaster story of last week, several readers suggested I should have a look at a utility called AppleJack. In hindsight, I cannot tell whether AppleJack would have been able to fix the problems that caused my Mac to refuse me access to my main user account. I sure wish, though, that I had it installed so I could at least have given it a try.
AppleJack is a shell script that provides command line access to the following tasks
- Repair disks
- Repair permissions
- Clean up cache files
- Validate preferences files (and move corrupted ones to a separate quarantine folder)
- Remove swap files
There is also an automatic mode which will perform all five tasks successively without requiring further user interaction. As a nice touch, AppleJack can also shut down or restart the Mac as soon as it has completed this automatic cycle.
In addition to AppleJack itself, the installer can optionally also install memtest, a useful command line utility for testing your machine's RAM. Very importantly, the package also includes extensive documentation in the form of a very well-written Read Me file, as well as UNIX man files for either utility.
AppleJack comes in handy in all those cases where you cannot access your usual arsenal of trouble-shooting tools, e.g., when you cannot log into your user account (sounds familiar, I'm afraid...): just hold down Command-S when restarting the Mac to boot into Single User Mode, and run AppleJack and/or memtest.
Either program only runs when launched -- there are no daemons installed. Hence, installing both utilities as part of your Macintosh emergency toolset does not pose any threat of its own to your Mac's wellbeing. In fact, you will surely regret it if you do not install AppleJack when that moment comes in which you realize that something isn't quite right with how your Mac behaves.
For an in-depth review of AppleJack, plus some additional information on general Mac OS X maintenance and trouble-shooting procedures, have a look this MacFixit article by Dan Frakes.
AppleJack is a 332kB download from the project's website and is distributed as donationware.
Categories
MacRead More Entries by Jochen Wolters.

Thanks for the clarification
klktrk
That's absolutely correct, of course. Thanks for the clarification!
Actually, it's freeware. Donations are requested, but there's no nagging and no registration prompt.