In the Utilities folder is an ap called Console. What is it for and how do you use it? It is basically just a log file viewer and it enables you to inspect a variety of logs. OS X records a wide range of activities and notes whether they were successful or if there was a problem. By inspecting the logs using Console you can track down errors. Here is one example showing how to fix a problem on the Mac.
Go to the Applications/Utilities folder and run Console.app. When it starts up, make sure that All Messages is selected in the left panel and the filter box in the top right corner is empty. The main part of the Console window is filled with messages and the latest ones are at the bottom. Scroll right down to the bottom and read up the screen because it's best to look at the most recent messages and work backwards.
The Console can be run at any time to examine the logs and it is useful to do so if you have just had a problem with an app. Another good time to run Console is immediately after booting up. Start your Mac and when it has finished booting, run Console. All the most recent entries are related to starting up and you can immediately see if there are any problems.
In the screen shot above you can see that there is a problem and a file could not be found in the Applications/Apps/WavePad.app/blah... folder. Quite why the Mac would want to access this file on startup is a mystery. Anyway, it is an app that I don't use, so I dragged it to the Trash. Now as you may or may not know, this does not remove all traces of an app and there are often files elsewhere on the disk. It is best if you track them down and delete them along with the app.
I fired up a freeware search tool called EasyFind. The search location was set to the Mac's hard disk and WavePad was the search term. Invisible Files and Folders was ticked at the bottom. It turned up several files related to WavePad.
If you right click (or Ctrl+click) an item in the results, there is an option to open the file location. This opens a Finder window so you can see the file. It can then be dragged to the Trash. So with all traces of the app now in the Trash, would the Mac boot without those error messages? Close all the apps and windows that are open, restart the Mac and when you get back to the desktop, run Console again. Look at the most recent entries at the bottom for the startup messages. The errors related to WavePad were gone.
Of course, this was a problem specific to this Mac and you may have completely different issues. Hopefully though, you can see how you can use Console to check for problems and find a solution. In this case deleting an app that was rarely used solved the problem, but with other problems an updated app, an OS X update or some other fix may be required. Check your logs in Console and see what is happening behind the scenes.