Skip to content
This repository has been archived by the owner on Dec 18, 2018. It is now read-only.

Microsoft.AspNetCore.Server.Kestrel.Internal.Networking.UvException and Error -4047 EPIPE broken pipe #1407

Closed
Damon227 opened this issue Feb 28, 2017 · 7 comments

Comments

@Damon227
Copy link

Exception message:

fail: Microsoft.AspNetCore.Server.Kestrel [0]
TcpListenerPrimary.OnConnection
Inner Exception(s) Found:
Type: Microsoft.AspNetCore.Server.Kestrel.Internal.Networking.UvException
Message: Error -4047 EPIPE broken pipe
Source: Microsoft.AspNetCore.Server.Kestrel
DataJson: {"$id":"1"}
Stacktrace:
at Microsoft.AspNetCore.Server.Kestrel.Internal.Networking.Libuv.Check(Int32 statusCode)
at Microsoft.AspNetCore.Server.Kestrel.Internal.Networking.UvWriteReq.Write2(UvStreamHandle handle, ArraySegment1 bufs, UvStreamHandle sendHandle, Action4 callback, Object state)
at Microsoft.AspNetCore.Server.Kestrel.Internal.Http.ListenerPrimary.DispatchConnection(UvStreamHandle socket)
at Microsoft.AspNetCore.Server.Kestrel.Internal.Http.TcpListenerPrimary.OnConnection(UvStreamHandle listenSocket, Int32 status)

@Damon227
Copy link
Author

I have a asp.net core web app in azure, but sometimes the httprequest will be locked and return 502, and the exception is Microsoft.AspNetCore.Server.Kestrel.Internal.Networking.UvException. My app's dll is 1.1.0.
"Microsoft.AspNetCore.Server.IISIntegration": "1.1.0",
"Microsoft.AspNetCore.Server.Kestrel": "1.1.0",
so who can give me some advicees?

@Damon227 Damon227 changed the title Kestrel Http Response Status Code 502 and Error -4047 EPIPE broken pipe Microsoft.AspNetCore.Server.Kestrel.Internal.Networking.UvException and Error -4047 EPIPE broken pipe Feb 28, 2017
@halter73
Copy link
Member

This looks like a dupe of #1182 which should be fixed in 1.1.0. Can you post your project.lock.json in a gist?

@Damon227
Copy link
Author

@halter73 Hi ! There is the project.lock.json. https://gist.github.com/Damon227/91c0cd5ba2af2fc72d475e7e83a4f7cb

@halter73
Copy link
Member

halter73 commented Feb 28, 2017

Looking at your project.lock.json, it looks like you you upgraded an app that started using AspNetCore 1.0.0 packages to use 1.1.0 packages. Since this looks so similar to a bug that was fixed in 1.0.0, could you triple check that the Web App you have published in Azure is really using the 1.1.0 Kestrel DLL?

One easy way to do this is to go to "https://{yoursite}.scm.azurewebsites.net" and navigate to the "Debug console > PowerShell" tab. In the powershell prompt, if you enter

(ls D:\home\site\wwwroot\Microsoft.AspNetCore.Server.Kestrel.dll).VersionInfo

What output do you get?

@Damon227
Copy link
Author

@halter73 Hi,I get this information fromn Kudu Debug console.

PS D:\home\site\wwwroot> (ls D:\home\site\wwwroot\Microsoft.AspNetCore.Server.Kestrel.dll).VersionInfo

ProductVersion FileVersion FileName


1.1.0-rtm-22752 1.1.0.21115 D:\home\site\wwwroot\Microsoft.AspNetCore....

So my app should be using the 1.1.0 Kestrel DLL. And i alse set Kestrel thread count = 1 at Program.cs in app.

@halter73
Copy link
Member

Do you still see the error when you set the thread count to 1?

@muratg
Copy link
Contributor

muratg commented Mar 20, 2017

ping @Damon227...

@muratg muratg closed this as completed Apr 7, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants