Reboot your computer.
Hold down CMD+S keys to go into single user mode. At the shell prompt (sh-2.05a$), type:
(This will run the file system check with the flag telling it 'yes' for every user prompt.)
This will run a file system check and answer yes to all of its questions automatically. After a series of test passes, it should return results. If it says:
***** FILE SYSTEM WAS MODIFIED *****
then you should re-run
fsck y and hit return. You should run it as many times as necessary until it reports no problems found. On my system, I only had to run it twice.
After successfully repairing the file system, at the sh-2.05a$ shell prompt, type reboot and hit return. Your computer will reboot.
If you notice that your computer boots faster, congratulations!
Mac OS X (and other UNIX operating systems) dont like to be shut down hard via an ungraceful restart or power failure. They typically run certain shutdown procedures and scripts when you logout, shutdown, or restart your computer. Over time, small corruption in the file system can accummulate and make booting slow or cause certain types of system instability. Semi-regular file system checks should be part of your regular OS X maintenence routine.