Asp.net
ASP.NET Core 2,IIS AppPool 崩潰並停止
我剛剛將一個 Web 應用程序更新為在 Windows Server 2008 R2 上的 IIS 7.5 上執行的 ASP.NET Core 2.0。由於升級應用程序會隨機崩潰並留下
503 Service Unavailable response. 它可以在崩潰前執行幾個小時。在崩潰之前,我在事件查看器中收到了幾個警告,然後是一個錯誤。
警告範例:
A process serving application pool '<My app pool>' terminated unexpectedly. The process id was '14896'. The process exit code was '0x0'.另一個警告範例:
A process serving application pool '<My app pool>' suffered a fatal communication error with the Windows Process Activation Service. The process id was '18252'. The data field contains the error number.錯誤範例:
Application pool '<My app pool>' is being automatically disabled due to a series of failures in the process(es) serving that application pool.我猜崩潰/錯誤來自 IIS 中的快速故障功能,但我無法確定原始警告的原因。
我也有一些執行時錯誤,如下所示,但我確定它們的相關性如何:
{ "@t": "2017-11-20T15:24:24.3190000Z", "@m": "Request timed out.", "@i": "0307d0fb", "@l": "Error", "@x": "Microsoft.AspNetCore.Server.Kestrel.Core.BadHttpRequestException: Request timed out.\r\n at Microsoft.AspNetCore.Server.Kestrel.Internal.System.IO.Pipelines.PipeCompletion.ThrowFailed()\r\n at Microsoft.AspNetCore.Server.Kestrel.Internal.System.IO.Pipelines.Pipe.GetResult(ReadResult& result)\r\n at Microsoft.AspNetCore.Server.Kestrel.Internal.System.IO.Pipelines.Pipe.Microsoft.AspNetCore.Server.Kestrel.Internal.System.IO.Pipelines.IReadableBufferAwaiter.GetResult()\r\n at Microsoft.AspNetCore.Server.Kestrel.Internal.System.IO.Pipelines.ReadableBufferAwaitable.GetResult()\r\n at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.MessageBody.<ConsumeAsync>d__24.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.Frame`1.<ProcessRequestsAsync>d__2.MoveNext()", "SourceContext": "xxxx.Extensions.GlobalExceptionFilter", "ActionId": "97118189-7c25-427b-82c7-10b3d885a146", "ActionName": "xxxx.Controllers.FileController.Upload (xxxx)", "RequestId": "0HL9G4JA0VTIJ:00000073", "RequestPath": "/api/file" }事件查看器還會報告相關應用程序池的以下錯誤:
An unhandled win32 exception occurred in w3wp.exe [18244]. Just-In-Time debugging this exception failed with the following error: Debugger could not be started because no user is logged on. Check the documentation index for 'Just-in-time debugging, errors' for more information.和…
Faulting application name: w3wp.exe, version: 7.5.7601.17514, time stamp: 0x4ce7afa2 Faulting module name: aspnetcore.dll, version: 7.1.1982.0, time stamp: 0x594ab904 Exception code: 0xc0000005 Fault offset: 0x000000000000fe3b Faulting process id: 0x1ef0 Faulting application start time: 0x01d3622d8eb0e8c0 Faulting application path: c:\windows\system32\inetsrv\w3wp.exe Faulting module path: C:\Windows\system32\inetsrv\aspnetcore.dll Report Id: ce37e890-ce20-11e7-9f93-00155dc82c03我真的可以使用一些幫助來嘗試找到這些崩潰的根源。
微軟現在已經為 ASP.NET Core 更新了 IIS 模組並解決了這個問題。