Application Gateway 기본 상태 프로브 ECONNRESET 예외

Application Gateway 기본 상태 프로브 ECONNRESET 예외

Azure VM의 웹 애플리케이션 앞에 애플리케이션 게이트웨이가 구성되어 있습니다. 기본 상태 프로브의 결과로 생성된 것으로 보이는 정기적인 ECONNRESET 예외가 발생하는 것을 확인했습니다. 30초마다 127.0.0.1에 대한 몇 가지 요청을 볼 수 있습니다. 상당히 정기적으로(지난 24시간 동안 20개 이상의 인스턴스) 해당 요청 중 하나는 아래 출력에 따라 ECONNRESET 예외를 발생시킵니다.

17:10:35 [Information] () "Request starting HTTP/1.1 GET http://127.0.0.1/  "

17:10:35 [Information] () {"Connection":["Keep-Alive"],"Host":["127.0.0.1"],"Max-Forwards":["10"]}

17:10:35 [Information] () Executing action method "HonestyBoxWeb.Controllers.HomeController.Index (HonestyBoxWeb)" with arguments (null) - ModelState is Valid

17:10:35 [Information] () Executing ViewResult, running view at path "/Views/Home/Index.cshtml".

17:10:35 [Information] () Executed action "HonestyBoxWeb.Controllers.HomeController.Index (HonestyBoxWeb)" in 2.8666ms

17:10:35 [Information] () "Request finished in 5.2758ms 200 text/html; charset=utf-8"

17:10:35 [Information] () Connection id ""0HLCE7PIFCIGH"" request processing ended abnormally.
System.IO.IOException: Error -104 ECONNRESET connection reset by peer ---> Microsoft.AspNetCore.Server.Kestrel.Transport.Libuv.Internal.Networking.UvException: Error -104 ECONNRESET connection reset by peer
   at Microsoft.AspNetCore.Server.Kestrel.Transport.Libuv.Internal.LibuvOutputConsumer.<WriteOutputAsync>d__6.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Microsoft.AspNetCore.Server.Kestrel.Transport.Libuv.Internal.LibuvConnection.<Start>d__26.MoveNext()
   --- End of inner exception stack trace ---
   at Microsoft.AspNetCore.Server.Kestrel.Internal.System.IO.Pipelines.PipeCompletion.ThrowFailed()
   at Microsoft.AspNetCore.Server.Kestrel.Internal.System.IO.Pipelines.Pipe.GetResult(ReadResult& result)
   at Microsoft.AspNetCore.Server.Kestrel.Internal.System.IO.Pipelines.Pipe.Microsoft.AspNetCore.Server.Kestrel.Internal.System.IO.Pipelines.IReadableBufferAwaiter.GetResult()
   at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.Frame`1.<ProcessRequestsAsync>d__2.MoveNext()

따라서 상태 확인이 요청을 게시한 다음 연결을 재설정하는 것처럼 보입니다. 제가 올바르게 해석하고 있나요? 이 문제를 해결할 수 있는 방법이 있나요?

답변1

이는 Kestrel 서버의 문제였으며 dotnet Core 2.1 릴리스에서 해결되었습니다.

참조:https://github.com/aspnet/KestrelHttpServer/issues/2540

관련 정보