Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

So recently I configured IIS6 to compress files I now have most files compressing apart from my JavaScript and CSS files. Does anyone have an idea what maybe causing them not to be compressed.

I know this due to Yslow Add-on and the compression directory I have set(see below) is empty

Service Tab Settings:

  • Compress application files: checked
  • Compress static files: checked
  • Temporary directory: %windir%\IIS Temporary Compressed Files
  • Max temporary directory size: unlimited

Metabase.xml Snippet:

<IIsCompressionScheme   Location ="/LM/W3SVC/Filters/Compression/deflate"
        HcCompressionDll="%windir%\system32\inetsrv\gzip.dll"
        HcCreateFlags="0"
        HcDoDynamicCompression="TRUE"
        HcDoOnDemandCompression="TRUE"
        HcDoStaticCompression="TRUE"
        HcDynamicCompressionLevel="5"
        HcFileExtensions="htm
            html
            txt
            ppt
            xls
            xml
            pdf
            xslt
            doc
            xsl
            htc
            js
            css"
        HcOnDemandCompLevel="10"
        HcPriority="1"
        HcScriptFileExtensions="asp
            dll
            exe
            aspx
            asmx
            axd"
    >
</IIsCompressionScheme>
<IIsCompressionScheme   Location ="/LM/W3SVC/Filters/Compression/gzip"
        HcCompressionDll="%windir%\system32\inetsrv\gzip.dll"
        HcCreateFlags="1"
        HcDoDynamicCompression="TRUE"
        HcDoOnDemandCompression="TRUE"
        HcDoStaticCompression="TRUE"
        HcDynamicCompressionLevel="5"
        HcFileExtensions="htm
            html
            txt
            ppt
            xls
            xml
            pdf
            xslt
            doc
            xsl
            htc
            js
            css"
        HcOnDemandCompLevel="10"
        HcPriority="1"
        HcScriptFileExtensions="asp
            dll
            exe
            aspx
            asmx
            ashx
            axd"
    >
</IIsCompressionScheme>

I have also given IUSR_{machinename} write permissions to "%windir%\IIS Temporary Compressed Files"

What I'm I missing?

Thanks for any help

share|improve this question

2 Answers 2

up vote 0 down vote accepted

Removed the js and css extensions from HcFileExtensions and added them to HcScriptFileExtensions

restarted IIS and its all working

share|improve this answer

Follow all the steps in this tutorial and you should be good:

http://engineering.leads360.com/post/9301650692/http-compression-gzip-on-iis-6

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.