httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vizzini Sampere <>
Subject Re: [users@httpd] Can't serve pre-compressed (gzip) html on Apache 2.0.55
Date Fri, 03 Feb 2006 01:19:22 GMT
On 2/2/06, Nick Kew <> wrote:
> > I'm having trouble configuring an Apache 2.0.55 (32-bit; linux;) to
> > serve pre-compressed (gzip 1.3.5) html files (for inline browser
> > rendering)
> That's usual.

Is anyone aware of a way to serve precompressed content in apache
2.0.x?  Multiviews, type-map or what ever?

I'm fairly certain if I can see a reproducible example of this
working, I can get it the rest of the way with type-map.

> > using AddHandler type-map.
> Why?  That's a bunch of added complexity.

When I use multiviews, I observe Apache slowing a good 20-30%.  I read
a lot of 'opinions' on the Internet, and came to believe the slowdown
is related to Apache performing an opendir on each hit just to search
for candidates matching  /^index\.*$/. like the '.htaccess' look-ups,
Apache does not cache these look-ups and they are done every single

Each of my directories has roughly 1k-5k files on average (just shy of
7k in the largest dir). When I used a type-map, apache appeared much
'snappier' under load and I could still have static content in both
html (4.0.1) and xml (1.0; xhtml 1.1).

> > Using the type-map, Firefox (1.5) and Safari (2.0.3) are not
> > displaying the content inline, they both want to download the
> > 'application/x-gzip' instead.
> That's what Content-Type is for.  See RFC2616.

I spent most of the afternoon re-reading it...  I still believe the goal is:
    Content-Encoding: gzip
    Content-Type: application/xml

Am I correct?

How do I get apache to offer this for static files? There are no
proxies involved between the broweser and server

The only time I observed apache injecting the 'Content-Encoding: gzip'
it explisityl overode the 'Content-Type: application/xml' that I
specified with 'Content-Type: application/x-gzip'. (see the last
ethereal summary from the first post)

> > Both browsers behave properly when
> > un-compressed files are dynamically compressed via mod_deflate
> > (verified with ethereal included bellow).
> They'll do that with compressed content too, if you don't mess up
> the content-type.

thanks for the reply!!!!

The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message