Output messages to a log file for inspection