Welcome! Log In Create A New Profile

Advanced

Re: Occasional misplaced gzip headers?

Maxim Dounin
April 05, 2010 06:34PM
Hello!

On Fri, Apr 02, 2010 at 05:18:56PM -0700, Frank Farmer wrote:

> Hi all,
>
> I've been seeing rare malformed responses from nginx with a strange
> 26 byte header prepended to them.
>
> $ od -c file.part | head
> 0000000 037 213 \b \0 \0 \0 \0 \0 \0 003 002 \0 \0 \0 377 377
> 0000020 003 \0 \0 \0 \0 \0 \0 \0 \0 \0 H T T P / 1
> 0000040 . 1 2 0 0 O K \r \n S e r v e
>
> The first two bytes look suspiciously like a gzip header.

Yep, looks like empty gzip file indeed. Such spurious bytes
before response may theoretically happen if subrequests are used
incorrectly (i.e.: do you use any 3rd party/your own modules?).

Could you please show nginx -V output and your config?

> I saw a problem like this back in April '09 when I first deployed
> nginx as a reverse proxy in front of Apache:
>
> http://stackoverflow.com/questions/736499/strange-http-gzip-issue

This is completely different problem and it's in Apache, not
nginx.

[...]

> Recently, we moved nginx to a separate box on the same LAN, keeping
> the same version (0.6.35 -- I know, it's old, but it's been stable).
> Suddenly, we're seeing very similar symptoms again. It doesn't
> happen reliably, and it doesn't happen often. I had one user report
> 3 instances over the course of 15 minutes. After receiving a
> garbled response, a second request for the same URL seems to
> succeed.

If you are able to reproduce the problem it whould be helpfull to
look into problematic request/response debug log as well. See
here for details:

http://nginx.org/en/docs/debugging_log.html

Maxim Dounin

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

Occasional misplaced gzip headers?

Frank Farmer April 05, 2010 02:04PM

Re: Occasional misplaced gzip headers?

Frank Farmer April 05, 2010 02:04PM

Re: Occasional misplaced gzip headers?

Maxim Dounin April 05, 2010 06:34PM

Re: Occasional misplaced gzip headers?

Frank Farmer April 05, 2010 06:58PM

Re: Occasional misplaced gzip headers?

Maxim Dounin April 05, 2010 08:16PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 104
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