Error Nginx 502 [upstream prematurely closed connection]
mdounin at mdounin.ru
Mon Oct 12 11:39:00 UTC 2015
On Sun, Oct 11, 2015 at 05:42:37PM -0400, javdev wrote:
> Hello guys this is my first question here.
> I'm working on nginx almost 2 years, but in the laste days I have founded an
> error, very complicated to solve.
> I'm working on Amazon stack, with Elastic Load Balancer (Using TCP (SSL)),
> then the request is sent to Nginx (1.8.0), 2 EC2 Instances, each instance
> has a Sails project (running on 1337 port).
> The connectio is amolst fine, actually sometimes works fine, but after 3 or
> 5 refresh page, throw the next 502 error:
> --- code error ----
> 2015/10/11 20:14:46 [error] 4623#0: *38 upstream prematurely closed
> connection while reading response header from upstream, client:
> 172.31.35.22, server: , request: "GET
> HTTP/1.1", upstream:
> host: "sails-load-balancer-1968414874.us-west-2.elb.amazonaws.com"
> ----- End code error----
The message suggests that something happened on your backend. You
have to look into its logs to find out more details.
More information about the nginx