Strange asp.net website crash with IIS 8.5 and Windows Server 2012 RC

GuillaumeDX 21 Reputation points
2021-03-30T15:45:33.397+00:00

Hi.

I have a legacy website built with ASP.NET WebForms, running on a Windows 2012 RC Server and IIS 8.5.

The app is running on .NET 4.5 framework. Recently, the website has suddenly stopped working during few minutes, and i've had to recycle the application pool on IIS to get back to a normal situation. When analyzing the windows events, i found a lot of errors:

Nom de l’application défaillante csc.exe, version : 4.7.3062.0, horodatage : 0x5ab95f85
Nom du module défaillant : KERNELBASE.dll, version : 6.3.9600.19304, horodatage : 0x5c7f684f
Code d’exception : 0xc0000142
Décalage d’erreur : 0x00000000000ecf30
ID du processus défaillant : 0x5864
Heure de début de l’application défaillante : 0x01d72255e27911be
Chemin d’accès de l’application défaillante : C:\Windows\Microsoft.NET\Framework64\v4.0.30319\csc.exe
Chemin d’accès du module défaillant: KERNELBASE.dll
ID de rapport : 203392fa-8e49-11eb-80c5-0cc47a91426f
Nom complet du package défaillant :
ID de l’application relative au package défaillant :

In the application logs i found this type of exception :

[26/03/2021 16:34:27] [NC1186] [c:\windows\system32\inetsrv\w3wp.exe] [Error] [General] [HandlingInstanceID: 4c54eaf3-2acd-43e3-8a54-7e23e2450838 An exception of type 'System.Web.HttpParseException' occurred and was caught. ----------------------------------------------------------------------------- 03/26/2021 16:34:27 Type : System.Web.HttpParseException, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a Message : Un composant externe a levé une exception. Source : System.Web Help link : 810c912 FileName : Access failed VirtualPath : Line : 0 ParserErrors : System.Web.ParserErrorCollection WebEventCode : 0 ErrorCode : -2147467259 Data : System.Collections.ListDictionaryInternal TargetSite : Void ProcessException(System.Exception) HResult : -2147467259 Stack Trace : à System.Web.UI.TemplateParser.ProcessException(Exception ex) à System.Web.UI.TemplateParser.ParseStringInternal(String text, Encoding fileEncoding) à System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding) à System.Web.UI.TemplateParser.ParseFile(String physicalPath, VirtualPath virtualPath) à System.Web.UI.TemplateParser.Parse() à System.Web.Compilation.BaseTemplateBuildProvider.get_CodeCompilerType() à System.Web.Compilation.BuildProvider.GetCompilerTypeFromBuildProvider(BuildProvider buildProvider) à System.Web.Compilation.BuildProvidersCompiler.ProcessBuildProviders() à System.Web.Compilation.BuildProvidersCompiler.PerformBuild() à System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath) à System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) à System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) à System.Web.Compilation.BuildManager.GetVirtualPathObjectFactory(VirtualPath virtualPath, HttpContext context, Boolean allowCrossApp, Boolean throwIfNotFound) à System.Web.Compilation.BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp) à System.Web.UI.PageHandlerFactory.GetHandlerHelper(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath) à System.Web.HttpApplication.MaterializeHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() à System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step) à System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) Additional Info: MachineName : XXXXXX TimeStamp : 26/03/2021 15:34:27 FullName : Microsoft.Practices.EnterpriseLibrary.ExceptionHandling, Version=5.0.414.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35 AppDomainName : ThreadIdentity : WindowsIdentity : IIS APPPOOL\XXXXXXX Inner Exception --------------- Type : System.Web.HttpCompileException, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a Message : Un composant externe a levé une exception. Source : System.Web Help link : Results : System.CodeDom.Compiler.CompilerResults SourceCode : WebEventCode : 0 ErrorCode : -2147467259 Data : System.Collections.ListDictionaryInternal TargetSite : System.CodeDom.Compiler.CompilerResults Compile() HResult : -2147467259 Stack Trace : à System.Web.Compilation.AssemblyBuilder.Compile() à System.Web.Compilation.BuildProvidersCompiler.PerformBuild() à System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath) à System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) à System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) à System.Web.Compilation.BuildManager.GetVPathBuildResult(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean ensureIsUpToDate) à System.Web.UI.BaseTemplateParser.GetReferencedType(VirtualPath virtualPath, Boolean allowNoCompile) à System.Web.UI.PageParser.ProcessMainDirectiveAttribute(String deviceName, String name, String value, IDictionary parseData) à System.Web.UI.TemplateParser.ProcessMainDirective(IDictionary mainDirective) ]

I really don't know why or how this errors occurred, and why i'll need to recycle application pool to stop them.
Cases i had check already:

  • The code is ok
  • The build was generated as usual, and all is fine without any changes since the incident.
  • CPU and memory was alright at crash moment.
  • No unclosed elements, format issue, or weird chars into aspx views
  • web.config was unchanged since lot of time and seems ok (no bindingRedirect repeated etc)

The server was not restarted from few months, is it a possible cause ? Can anybody helps me with this probleme please ? I want to avoid another crash like this one in the future. By advance thanks for help.

Internet Information Services
ASP.NET
ASP.NET
A set of technologies in the .NET Framework for building web applications and XML web services.
3,507 questions
Windows Server 2012
Windows Server 2012
A Microsoft server operating system that supports enterprise-level management, data storage, applications, and communications.
1,599 questions
0 comments No comments
{count} votes

Accepted answer
  1. Sam Wu-MSFT 7,531 Reputation points Microsoft Vendor
    2021-04-01T07:13:09.207+00:00

    Hi @GuillaumeDX

    There are several reasons which can cause this error in your computer. One of these is a corrupted or missing system file. You may run the System File Checker to identify and troubleshoot this error.

    You can also follow the steps through Fix Windows Update errors by using the DISM or System Update Readiness tool to check for any update errors.

    Note: Please perform the Clean boot on your PC.

    Clean Boot temporarily disables all third party applications as well as all Microsoft non-essential services so only basic drivers will run. This will help us find any third-party software which can be the cause of this issue.

    Here are the steps:

    1. From Start, search for msconfig
    2. Select System Configuration from the search results.
    3. On the Services tab of the System Configuration dialog box, tap or click to select the Hide all Microsoft services check box, and then tap or click Disable all.
    4. On the Startup tab of the System Configuration dialog box, tap or click Open Task Manager.
    5. On the Startup tab in Task Manager, for each startup item, select the item and then click Disable.
    6. Close Task Manager.
    7. On the Startup tab of the System Configuration dialog box, tap or click OK, and then restart the computer.

    If the answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    1 person found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. MotoX80 34,421 Reputation points
    2021-03-30T18:28:00.79+00:00

    C:\Windows\Microsoft.NET\Framework64\v4.0.30319\csc.exe is the C# compiler. Were your application developers making changes to the site while end users were actively using it? If this is a big site, it might take time to recompile.

    You could try taking the app offline before the next site update.

    https://activedirectoryfaq.com/2015/01/iis-maintenance-page-app_offline-htm/


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.