Gazelle icon indicating copy to clipboard operation
Gazelle copied to clipboard

Vague `failed to writev` error

Open frioux opened this issue 9 years ago • 8 comments

Sometimes our server prints out the error: failed to writev from either line 265 or line 238, which call write_chunk and write_psgi_response respectively. It would be nice if they included a little bit more information like why writev failed. Not a big deal though.

frioux avatar Oct 01 '15 17:10 frioux

Do you have a sample code that reproduce this problem?

kazeburo avatar Oct 06 '15 16:10 kazeburo

Sadly no, it happens very rarely in production only

sent from a rotary phone, pardon my brevity On Oct 6, 2015 11:15 AM, "Masahiro Nagano" [email protected] wrote:

Do you have a sample code that reproduce this problem?

— Reply to this email directly or view it on GitHub https://github.com/kazeburo/Gazelle/issues/16#issuecomment-145916423.

frioux avatar Oct 06 '15 17:10 frioux

In my environment, failed to writev: -1 errno:32 is printed in log. This is EPIPE error. I think that Gazelle should ignore EPIPE error.

karupanerura avatar Mar 24 '16 09:03 karupanerura

I didn't know what an EPIPE error was. I found this discussion which said:

EPIPE means that writing of (presumably) the HTTP request failed because the other end closed the connection.

dnmfarrell avatar Apr 22 '16 14:04 dnmfarrell

Agree with @karupanerura, I get these messages a lot in my logs :(

failed to writev: -1 errno:32 at [...]vendor_perl/5.22.1/x86_64-linux/Plack/Handler/Gazelle.pm line 255.

This happens I presume when the client side closes the connection before receiving all the data. Would be nice if it was ignored.

vti avatar Dec 12 '17 15:12 vti

For what it's worth I think this stopped happening to us entirely when we moved to nginx, which does not expose the underlying server to client disconnects at all.

frioux avatar Dec 13 '17 18:12 frioux

I also have nginx in front. Probably I should just switch to uwsgi.

vti avatar Dec 13 '17 18:12 vti

I am having the same message error in my logs. It happens many times each day. I also think it would be nice if this error is just ignored.

everissimo avatar Mar 25 '20 08:03 everissimo