Nginx stops sending file after ~1.5mb ?

Yo'av Moshe bjesus at
Sun Jan 11 16:43:36 MSK 2009

I'm using Nginx to serve a few TurboGears projects and some Wordpress sites.
Mostly is does it job more than well, but lately I'm facing some problems
serving not-so-big static files.

The files come statically, and not from an upstream server.

        location ^~ /static/  {
            root /home/user/some/static/directory;
            gzip on;
            gzip_comp_level 9;
            gzip_types text/plain text/css application/x-javascript text/xml
application/xml application/xml+rss text/javascript;
            expires max;

Try this link for example, which is a 1.9mb PDF file uploaded by one of my
If I'm correct, it will stop after ~1.5mb. The speed drops to 0K/s, and my
logs show a timeout:
2009/01/11 15:36:48 [info] 546#0: *612 client timed out (110: Connection
timed out) while sending response to client, client:,
server:, request: "GET
/static/uploads/u-20/%5B1231615256%5Dhozer.pdf HTTP/1.0", host: "

I've tried it both from my browser and using wget - exactly same thing.

What could be causing that?

I have
    tcp_nopush        on;
    client_max_body_size 500M;
    gzip  on;
on my http {} part
        client_header_buffer_size    1k;
        large_client_header_buffers  8 8k;
in the server {} one.

But commenting them didn't make a difference.

Any idea would be kindly appreciated.

Yo'av Moshe
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the nginx mailing list