You’ll want to look at the system error log from time to time. In Mac OS X, this is an application called Console. It can be found here:
/Applications/Utilities/Console
It will look something like this: