Re: haproxy get 502 when downloading large files from IIS

From: Willy Tarreau <w#1wt.eu>
Date: Thu, 8 Jul 2010 22:54:32 +0200


On Thu, Jul 08, 2010 at 04:47:24PM -0400, Cheng, Xin [USA] wrote:
> Hello there,
>
> We have problem of downloading large files through haproxy from IIS share point and MSSQL in the back.
> User cannot download large files like over 28MB.
> But user is able to upload large files and download small files.
> Error in the haproxy.log:
>
> Jul 8 11:29:52 localhost haproxy[16087]: 10.200.2.252:31047 [08/Jul/2010:11:27:31.914] url-proxy hello_sharepoint/iis2 4/0/0/-1/140204 502 204 - - SHVN 0/0/0/0/0 0/0 "GET /personal/026342/Lists/SharedDocs/creating_a_wiki_page_on_hello.mov HTTP/1.1"
>
> Our haproxy is 1.4.4 which runs in enterprise SUSE 11
> Linux SNSproxyQA02 2.6.27.45-0.1-pae #1 SMP 2010-02-22 16:49:47 +0100 i686 i686 i386 GNU/Linux
>
> I set this
> net.ipv4.tcp_frto=0
> in sysctl.conf. It did not fix the problem.
>
> Any guru have any insights?

The logs indicate a connection close (or reset) from the server after 140 seconds and no data in return. Are you sure you're not having any equipment between haproxy and the server which inspects contents and which dies on large files ? Eg: an anti-virus reverse proxy or something like this which buffers the whole file and crashes the process ? It looks very well like this. Just in case, you should try to capture the network traffic between haproxy and your server to check, but it looks like a very likely issue.

Also, are you sure that your server can serve the file from a client not passing through haproxy ?

Regards,
willy Received on 2010/07/08 22:54

This archive was generated by hypermail 2.2.0 : 2010/07/08 23:00 CEST