Search This Blog

Tuesday, November 25, 2014

Debugging : Compare Logs

Many a times we come to a situation where we know that one scenario is working and other scenario is not working in SharePoint implementation. e.g. search is returning results for authenticated users and not working for anonymous users so we need to debug such situation thoroughly and in order to debug sharepoint logs are the best pointers to start with.

Now the difficult part is to scan the huge log files and that too with verbose mode on. So we can quickly go to server and fireup some powershell commands to get desired log files without putting any load on the server


Enable verbose mode on with powershell

Set-SPLogLevel -TraceSeverity verboseEx -EventSeverity verbose

Create a new log file to collect only working scenario data. Notedown the time when you fire this command to save it later



Now go the client machine and execute the working scenario. Once done then run the New-SPLogFile again and save the latest file created with file from the folder

C:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\LOGS

Now run the scenario that was not working. Once done then run the  New-SPLogFile again and save the new file

Now you need to run Clear-SPLogLevel to reset back the default log level

No comments:

Post a Comment