This post has been republished via RSS; it originally appeared at: IIS Support Blog articles.
Here is the error message displayed for one of the applications after I enabled Failed Request Tracing in the IIS server:
Cannot add duplicate collection entry of type ‘add’ with unique key attribute ‘path’ set to ‘*’
Since the error message mentions a duplicate record, check the web.config for identical definitions:
- Enable Failed Request Tracing
- Add a rule
- If the issue occurs, check web.config file. Are there identical Failed Request Tracing rules?
If there are no duplicates, check the rules in tracing module at all application, site, and server levels in IIS Manager. Make sure there are no conflicting rules.
If the issue still persists, add the line below into web.config. It will remove all existing rules to prevent duplication.
The entire configuration of the Failed Request Tracing rule in the web.config:
Note: In my case, the environment this issue occurred had two IIS servers pointing to the same web.config (located in a network share).