4

One of my client's SharePoint 2013 site always displays the Runtime Error screen if there is some error instead of the "Sorry Something went wrong." page with the correlation ID. Error

This makes it impossible to troubleshoot the error since correlation id is not available. Is there some setting I need to change to get the "Sorry, something went wrong page" with correlation id like the one below?

enter image description here

2

Error page itself states what needs to change. Problem is with setting of your site's web.config

  • Locate web.config for your site.
  • You find it at below path

    Drive\Inetpub\Wwwroot\WSS\VirtualDirectories\<port number of your web-application>\web.config

  • Open a notepad with administrator privileges (right click and run as admin)

  • Use open command, move to the path of web.config.
  • Open web.config of you site.
  • Search for CustomError keyword/tag
  • Change its mode property to "Off"
3
  • My intention is not to display the stack trace on the page(this is a production site) but to display the SharePoint 'Sorry Something went wrong'error page. Turning Off CustomErrors in web.config file will just dump the error details on the screen which I do not want. – SharePoint Badger Jul 8 '16 at 6:10
  • my approach will give turn the custom page off and will show you correlation ID page – Gaurravs Jul 8 '16 at 7:18
  • you can test it on dev before moving to production – Gaurravs Jul 8 '16 at 7:19
1

Correlation IDs are generated from SharePoint processes. That Yellow Screen of Death was thrown by custom code. With custom code the developer is generally responsible for proper exception handling, including redirecting to a custom error page, displaying a helpful message to the end user, and logging pertinent details. Unless that custom code is written explicitly to log exception details to the SharePoint logs, there will be nothing there for you to find.

For non-production environments you can disable custom error and output the stack trace to the page. The process is somewhat involved, you can read about it here: https://cann0nf0dder.wordpress.com/2013/01/11/debugging-sharepoint-2010-_layout-pages-and-turn-off-custom-errors/

1
  • the yellow runtime error screen was shown when using the OOTB 'Check Permissions' function. It is not from a custom application. – SharePoint Badger Jul 8 '16 at 6:21
1

Finally managed to get the sharepoint error page by changing the value for CallStack from true to false in web.config.

<SafeMode MaxControls="200" CallStack="false" DirectFileDependencies="10" TotalFileDependencies="250" AllowPageLevelTrace="false">

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.