How-to search system logs for BYOD (and other) errors in D365 F&O
In this article I will show how to search the system logs for errors in the running of BYOD jobs. The obvious place to look for error messages is in the Job history of the BYOD job, but sometimes the message there is not detailed enough to understand what caused your job to fail.
Here, I have a BYOD job containing 2 entities, one of which failed. In order to see the error message, I click on “Execution details” in the Job history and then “View execution log”:
In the execution log, there are a few things to look for, the first obviously being the error message itself. However, the error message may be too generic or even non-existent.
You will notice that the Staging status is ‘Ended’ meaning that the staging of the data to be imported in the BYOD job ran without issue, but the Target status is in ‘Error’. This means that the writing of the data into the destination caused the job to error out. The Log text for the Source (i.e. staging) is displayed and tells us that “’154316′ ‘Sales transactions’ record(s) inserted in staging”
Then, by selecting the Target, you can see the Log text for the staging part of the run does not give any details:
So, what do we do now? It is apparent that the Job history does not give us enough details (in this case) to resolve the issue. And we simply cannot do nothing because the error will occur again in the next run of the BYOD job.
Let’s log on to the LCS and look through the raw log files. You may also hear this log referred to as the ‘telemetry log’.
How-to search system logs for BYOD (and other) errors
Log on to the LCS and select the implementation for your company:
Click “Full details” for the environment in which the error occurred:
Click on “Environment monitoring” in the bottom half of the screen:
Next, click on “View raw logs”:
Enter a Start date, an End date, and any Search terms (comma separated), then click “Search”:
Note: In the drop down box for Query name, you will see a listing of events through which you can search:
Note: If you click “Show options”, you will be able to select how many rows to bring back and make the search time non-UTC:
After you click “Search”, you will see a message that the log files are being searched for your Search terms:
Once the search results are returned, you will see a listing of activities with many columns of information. Scroll to the right until you see column titled LevelName. This column contains keywords such as Information and Error:
Click on the column header LevelName (or alternatively, scroll downwards until you see “Error”):
Scroll to the right until you see the column titled exceptionMessage, which will contain the message associated with that error:
You can copy & paste this message into another file/document to help you decipher its meaning and to determine steps to rectify the issue.
When finished, click the X in the top right corner to close this search.
Congratulations, you have searched system logs of D365 F&O via LCS for BYOD (and other) errors.