Consider a multi-server SharePoint FARM where you come across an error and SharePoint provides you just a Correlation ID. It can get very tedious for the administrator to find the actual error, especially scanning the logs on all servers.
There is a much easier option available in PowerShell which will return logs for a particular Correlation ID from the entire FARM.Merge-SPlogfile - PowerShell command
The "Merge-SPlogfile" command will search the error logs for the given correlation error ID from all the servers in FARM.
The output file can be generated in the desired format (log, xls, etc) and placed on any location on the server.Merge-SPLogFile -Path [FILE PATH] -Correlation [CORRELATION GUID]
where, Merge-SPLogFile = PowerShell Command Path = Location where the output file is to be saved, along with File Name and extension Correlation = The correlation id (GUID) of the error
Start SharePoint Management Shell (run as administrator) and execute below PowerShell command.
Merge-SPlogfile -Path C:\sp_error.xls -Correlation xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
This will generate a file named "sp_error.xls" at location C:\. The generated file will consist only errors related to the correlation id provided in the command.
If you want to understand how the correlation id is helpful in troubleshooting the error, read here - http://code2care.org/2015/an-unexpected-error-has-occurred
- Managed Metadata error - The data returned from the tagging UI was not formatted correctly
- How to generate client id and secret to register SharePoint App with OAuth
- Create SharePoint Site Collection with new Content database in existing web application
- Fix Error 2711 SQL RBS client - The installer has encountered an unexpected error. The specified Feature name ('Docs') not found in Feature table
- How to exclude results from SharePoint Search
- 'Edit Document' Requires a Windows Sharepoint Services-compatible application and Microsoft Internet Explorer 6.0 or higher
- [Solved] SharePoint Access Denied error editing Document Name
- Recommended size and resolution for SharePoint Online Site logo
- SharePoint Server 2016 IT Preview - new improved Features and Enhancements
- Restore deleted Office 365 SharePoint group site
- SharePoint An unexpected error has occurred - Correlation ID and PowerShell Merge-SPlogfile
- [Solved] SharePoint Search Internal server error exception
- SharePoint CAML query error - The XML source is not correct
- How to hide quick launch in SharePoint classic site
- Not receiving email notification alert in SharePoint Online workflow - Power Automate, FLOW
- Change SharePoint search results FullTextSqlQuery RowLimit 10000
- Fix Power BI error Access to the resource is forbidden when connecting SharePoint Online List as data source
- [Fix] Restricted View permission level missing in SharePoint Online site library
- How to upload file programmatically to SharePoint Document Library using Server Object Model C# .Net
- How to create classic site in SharePoint Online
- That did'nt work, Issue type User not in directory - SharePoint external access error
- Merge-SPlogfile PowerShell - SharePoint Correlation ID error
- Fix Power BI 404 not found error when connecting SharePoint Online List as Data Source
- SharePoint Server 2016 IT Preview Deprecated Removed features
- SharePoint error - An exception occurred when trying to issue security token: This implementation is not part of the Windows Platform FIPS validated cryptographic algorithms..
- XmlRpcException ConnectException connection refused error - Java
- Free and easy audio video screen recording using Microsoft PowerPoint - Microsoft
- Android appcompat_v7 Error retrieving parent for item: No resource found that matches the given name - Android
- Todays Apple Spring Loaded Event Live Updates - Apple
- [Fix] Java Exception with Lambda - Cannot invoke because object is null - Java
- How to Change Text Size for Android ActionBar - Android
- Android Toolbar example with appcompat_v7 21 - Android