Nginx+Passenger: 502 Bad Gateway from Nginx when passing urlencoded URLs in GET vars
- by jimeh
Here's an example of the URLs that don't work:
http://domain/do?url=http%3A%2F%2Fwww.linkedin.com%2Fin%2Fperson
http://domain/do?url=http%3A%2F%2Fwww.linkedin.com%2F
However, the following URL does work:
http://domain/do?url=http%3A%2F%2Fwww.linkedin.com
Also, this only happens with Nginx, using Passenger with Apache it works fine, but we use Nginx on our production machines.
Here's the entry in Nginx's error log:
2009/12/01 09:30:51 [error] 6407#0: *136 upstream prematurely closed connection while reading response header from upstream, client: xxx.xxx.xxx.xxx, server: domain, request: "GET /do?url=http%3A%2F%2Fwww.linkedin.com%2F HTTP/1.1", upstream: "passenger://unix:/tmp/passenger.6335/master/helper_server.sock:", host: "domain"