Start a conversation

How to enable Trace Logging for Failed Requests (IIS 7)

You can enable trace logging for failed requests when you want to log information about failed requests to an IIS site or application. When trace logging for failed requests is enabled, IIS provides targeted logging so that you no longer have to look through a list of irrelevant log entries to find a failed request. Additionally, you do not have to re-create an error in order to troubleshoot it.

You can configure:

  • The location of the log file
  • The maximum number of log files to keep
  • The maximum size of the log files

To enable site-level trace logging for failed requests

You can perform this procedure by using the user interface (UI), by running Appcmd.exe commands in a command-line window, by editing configuration files directly, or by writing WMI scripts.

User Interface

To Use the UI

  1. Open IIS Manager and navigate to the level you want to manage. 

  2. In the Connections pane, click Sites.

  3. In Features View, select the site for which you want to enable trace logging.

  4. In the Actions pane, under Configure, click Failed Request Tracing.

  5. In the Edit Web Site Failed Request Tracing Settings dialog box, select Enable to enable logging for this site.

  6. In the Directory text box, type the path where you want to store the log files or click the browse button () to find a location on the computer. The default is %SystemDrive%\inetpub\logs\FailedReqLogFiles.

Choose files or drag and drop files
Was this article helpful?
  1. Senior Engineer Jessie

  2. Posted
  3. Updated