Maxim Dounin
September 17, 2013 11:40AM
Hello!

On Tue, Sep 17, 2013 at 11:11:05AM -0400, Claudio wrote:

> Hi.
>
> I've set up nginx as a proxy for a jetty service. Works nicely, most of the
> time, except
>
> ... when issuing a (somewhat) larger POST request to some entity which is
> protected by HTTP Basic access authentication.
>
> The web app responds with a 401 immediately, probably closing the connection
> right away:
>
> 127.0.0.1 - - [17/Sep/2013:14:17:38 +0000] "POST /scm/blub?cmd=unbundle
> HTTP/1.0" 401 1412
>
> But nginx gratuitously insists on sending all the data, which fails
> eventually:
>
> 2013/09/17 16:17:38 [error] 22873#0: *1 writev() failed (32: Broken pipe)
> while sending request to upstream, client: 192.168.2.8, server: test.int,
> request: "POST /scm/blub?cmd=unbundle HTTP/1.1", upstream:
> "http://127.0.0.1:8082/scm/blub?cmd=unbundle", host: "test.int"
>
> I also tried different config options like enabling sendfile, increasing
> buffer and timeout sizes, but it didn't help.
>
> Is there some way to make this work? Is this a bug?

As long as a connection is closed before nginx is able to get a
response - it looks like a problem in your backend. Normally such
connections need lingering close to make sure a client has a chance
to read a response.

--
Maxim Dounin
http://nginx.org/en/donation.html

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Broken pipe while sending request to upstream

Claudio September 17, 2013 11:11AM

Re: Broken pipe while sending request to upstream

Maxim Dounin September 17, 2013 11:40AM

Re: Broken pipe while sending request to upstream

Claudio September 18, 2013 02:52AM

Re: Broken pipe while sending request to upstream

Maxim Dounin September 18, 2013 09:24AM

Re: Broken pipe while sending request to upstream

Claudio September 20, 2013 03:27AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 276
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready