Diagnostic logging for mail services

Version 8

    Comprehensive guide to diagnostic logging for mail services

     

    Inbound mail service

     

    • Navigate to the Service Desk installation directory of your Service Desk Server and open the file “Touchpaper.Service.Mail.Inbound.WindowsService.exe.config” in a text editor and change the value for the following key

              from <add key="Log Severity" value="Error" /> to <add key="Log Severity" value="Trace" />

     

            In 7.5 the Configuration Centre should be used for the configuration.

     

    • After this change save the file and restart the “Touchpaper Inbound Mail Engine” service in the windows services management. This switches on detailed logging for inbound mail service and the logs are found in the windows application event log

     

    • Try replicating the steps to reproduce the problem/error which you are facing in Service Desk so that this is captured in detail in application event log. For example you can send in a mail to your console inbox account to log a new test mail OR if some mail has failed to get logged as an incident, set this as unread in service desk inbox and let inbound mail service read it again. You will have to wait till the mail service polls. Once polled this will create an event log error message which can then be investigated

     

    • Once done set the log severity value in the above mentioned file back to “Error” and restart the “Touchpaper Inbound Mail Engine” service in the windows services management. Please save a copy of your windows application event log and send it to your support analyst for investigation

     

    Outbound mail service

     

    • Navigate to the Service Desk installation directory of your Service Desk Server and open the file “Touchpaper.Service.Mail.Outbound.WindowsService.exe.config” in a text editor and change the value for the following key

     

              from <add key="Log Severity" value="Error" /> to <add key="Log Severity" value="Trace" />

     

            In 7.5 the Configuration Centre should be used for the configuration.

     

    • After this change save the file and restart the “Touchpaper Outbound Mail Engine” service in the windows services management. This switches on detailed logging for outbound mail service and like inbound this too logs events in the windows application event log

     

    • Try replicating the steps to reproduce the error message for outbound mail services in application event log. For example you can add a note in a test incident which sends a reminder via outbound mail. You will have to wait till the mail service polls. Once polled this will create an event log error message which can be then investigated

     

    • Once done set the log severity value in the above mentioned file back to “Error” and restart the Touchpaper Outbound Mail Engine” service in the windows services management. Please save a copy of your windows application event log and send it to your support analyst for investigation.

     

    Notes:

     

    • It is assumed here that you are running mail services as windows services and not as system tray application
    • This article has been tested for Service Desk versions 7.2.5, 7.2.6 and 7.3

     

    Tips:

     

    • It is important that you do not forget to set the log severity back to Error otherwise depending upon usage and traffic on your site the log files can quickly become very large and fill up disk space. Apart from that this takes a toll on the performance of the system
    • The log severity value is not case sensitive so it doesn’t matter if you write “Trace” or “trace”
    • The log severity value “All” logs all errors and warnings only and does not switch on detailed diagnostic logging
    • The log severity value “Warning" OR "Warnings" is the same as "All” so this too logs all errors and warnings and does not switch on detailed diagnostic logging. This could be useful when you want to monitor eventlog for warnings. e.g. when large attachements are rejected due to their size a warning is generated in the event log.
    • Another valid log severity value is "information" which has the same logging level as "trace"
    • The key <add key="Detailed Logging"  value="false" /> does not have any effect on diagnostic logging. So changing this value to “true” does not have any effect
    • Every time outbound mail service restarts it writes a log file in C:\WINDOWS\system32. This log file is named Outbound Mail Log ‘date’ ‘time’.txt e.g. "Outbound Mail Log 10.09.2009" 14-47-31.txt”. This log file is always empty regardless  of diagnostic logging being turned on or off. So the only place to look for logs is the windows application event log. The inbound mail service on the other hand does not have this behavior