LiteSpeed Technologies
Download Download     Blog Blog     Wiki Wiki     Forum Forum     Store     Contact Contact    

Go Back   LiteSpeed Support Forums > LiteSpeed Web Server > Install/Configuration > poor compression (gzip - png)

Reply
 
Thread Tools Display Modes
  #1  
Old 07-20-2009, 07:13 PM
Jan Guti Jan Guti is offline
New Member
 
Join Date: Jul 2009
Posts: 5
Default poor compression (gzip - png)

Hello.. i noted that with litespeed the png images do not get compressed, im using another server with nginx and the compress ratio is more than 60%, nginx uses gzip too. Is this normal with litespeed? Is not gzip the same in whatever server is running?

The compression is important for me because the server is serving png images, the compression of html, css is woorking great.

And i have added in server > tuning > Compressible Types > image/png

running litespeed 4.0.6, testing with yslow

JG
Reply With Quote
  #2  
Old 07-20-2009, 07:15 PM
mistwang mistwang is offline
LiteSpeed Staff
 
Join Date: May 2003
Location: New Jersey
Posts: 7,585
You can try increase the compression level, litespeed uses "1" as the default, you can try "9".
Reply With Quote
  #3  
Old 07-20-2009, 07:22 PM
Jan Guti Jan Guti is offline
New Member
 
Join Date: Jul 2009
Posts: 5
I have tried from 1 to 9 and there is no change in the results.

JG
Reply With Quote
  #4  
Old 07-20-2009, 07:27 PM
mistwang mistwang is offline
LiteSpeed Staff
 
Join Date: May 2003
Location: New Jersey
Posts: 7,585
For static file, the compressed results are cached,
http://www.litespeedtech.com/docs/we.../#gzipCacheDir

clear the cache directory, or touch the png file to trigger cache invalidation.
Reply With Quote
  #5  
Old 07-20-2009, 09:09 PM
Jan Guti Jan Guti is offline
New Member
 
Join Date: Jul 2009
Posts: 5
I deleted the cache and the compression stop working even for text, i uninstalled litespeed and reinstalled but compression for png is the same as uncompressed, text is working fine.
Reply With Quote
  #6  
Old 07-20-2009, 10:39 PM
mistwang mistwang is offline
LiteSpeed Staff
 
Join Date: May 2003
Location: New Jersey
Posts: 7,585
Have you checked the response header with firebug for "Content-encode: gzip"?
Is a png file compressed, just like a gif file? If it is compressed already, compress again wont make it any smaller.
Reply With Quote
  #7  
Old 07-21-2009, 08:15 AM
Jan Guti Jan Guti is offline
New Member
 
Join Date: Jul 2009
Posts: 5
Yes, there is something wrong, same image:

image in litespeed server: (compression level 6)
Code:
http://publikando.com/test1.png

same image in nginx server: (compression level 4)
Code:
http://publikacion.de/test1.png
JG
Reply With Quote
  #8  
Old 07-21-2009, 08:30 AM
mistwang mistwang is offline
LiteSpeed Staff
 
Join Date: May 2003
Location: New Jersey
Posts: 7,585
gzip compression has no effect from both result, as expected.
Checked with YSlow.
Reply With Quote
  #9  
Old 07-21-2009, 07:45 PM
Jan Guti Jan Guti is offline
New Member
 
Join Date: Jul 2009
Posts: 5
In my side.. 2 different computers (vista, w7 and ie8 ) with yslow:

In litespeed:
SIZE (KB): 37.8K GZIP (KB): 40.7K
Date Tue, 21 Jul 2009 15:45:12 GMT
Server LiteSpeed
Accept-Ranges bytes
Etag "9ee0-4a65d5eb-0"
Last-Modified Tue, 21 Jul 2009 14:51:23 GMT
Content-Type image/png
Content-Length 40705
Content-Encoding gzip
Vary Accept-Encoding


In nginx:
SIZE (KB): 37.8K GZIP (KB): 12.6K
Server nginx
Date Tue, 21 Jul 2009 14:50:05 GMT
Content-Type image/png
Last-Modified Tue, 21 Jul 2009 14:49:35 GMT
Vary Accept-Encoding
Expires Wed, 22 Jul 2009 14:50:05 GMT
Cache-Control max-age=86400
Content-Encoding gzip

So this mean the compression is side dependent, and my computer, browser, etc.. can affect this. Now i have to investigate how i obtaining a more of 60% compression in my side from nginx png.

JG
Reply With Quote
  #10  
Old 07-22-2009, 12:16 PM
mistwang mistwang is offline
LiteSpeed Staff
 
Join Date: May 2003
Location: New Jersey
Posts: 7,585
nginx uses chunked encoding, so the total length could be mis-calculated for some reason.

It is not difficult to get the real response body length with command line tools.
You can also try GZIP compress the png file from command line see what you can get.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 12:48 AM.



- Archive - Top
© Copyright 2003-2011 LiteSpeed Technologies, Inc. All rights reserved. Privacy Policy.