Search code examples
c#.netasp.netparsingperfmon

"Errors During Preprocessing" is non-zero in ASP.NET perfmon counters


While testing an ASP.NET application with perfmon, we find that the following field is non-zero:

ASP.NET Apps v2.0.50727 > Errors During Preprocessing

Documentation says that this field is "The number of errors that occurred during parsing, excluding compilation and run-time errors."

However, I have not been able to track down why this is happening. Any clues on where these actual preprocessing errors are logged? Or how to enable logging so we can fix these errors?


Solution

  • One thing I would try is to precompile your application from the command line using aspnet_compiler. e.g. from a VS command window, try something like:

    aspnet_compiler -v / -p c:\PathToYourAppRoot
    

    At runtime, there is some fallback behavior which may mask some errors. But when running aspnet_compiler, it should be catching and displaying any error that it encounters.

    If that doesn't help, another thing you can try to isolate the issue is figure out after what specific http request the counter goes up. e.g. does it go up as soon as you send the first request, or only after hitting specific URLs?