[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[users@httpd] Re: brotli module loaded but doesn't work


Le 22/06/2018 à 09:52, Michael A. Peters a écrit :
> On 06/22/2018 12:35 AM, Michael A. Peters wrote:
> *snip*
>
> Okay looks like a difference between what is actually in Apache and what
> websites idicate.
>
> Seems with the code in Apache, for the filter BROTLI_COMPRESS is correct
> - not BROTLI.
>
> Not sure about setting compression level and window size
>
> But it seems that building the module from a git checkout from
> https://github.com/kjdev/apache-mod-brotli/ results in different
> configuration from building the module via apache source.
>
>> Looks good, the module is loaded. But - if I have:
>>
>> <IfModule brotli_module>
>>   # Compression
>>   ## BrotliCompressionLevel: 0-11 (default: 11)
>>   BrotliCompressionLevel 10
>>
>>   ## BrotliWindowSize: 10-24 (default: 22)
>>   BrotliWindowSize 22
>>
>>   # Logging
>>   # Filter note
>>   BrotliFilterNote Input  brotli_in
>>   BrotliFilterNote Output brotli_out
>>   BrotliFilterNote Ratio  brotli_ratio
>>
>>   #LogFormat '"%r" %{brotli_out}n/%{brotli_in}n (%{brotli_ratio}n)'
>> brotli
>>   #CustomLog ${APACHE_LOG_DIR}/brotli_access.log brotli
>>
>>   # Output filter
>>   AddOutputFilterByType BROTLI text/html text/plain text/css text/xml
>>   AddOutputFilterByType BROTLI text/css
>>   AddOutputFilterByType BROTLI application/x-javascript
>> application/javascript
>>   AddOutputFilterByType BROTLI application/rss+xml
>>   AddOutputFilterByType BROTLI application/xml
>>   AddOutputFilterByType BROTLI application/json
>>
>>   # Global output filer if necessary.
>>   # SetOutputFilter BROTLI
>>   # SetEnvIfNoCase Request_URI \.txt$ no-br
>>
>> </IfModule>
>>
>> then apache won't start:
>>
>> [alice@localhost ~]$ apachectl -M
>> AH00526: Syntax error on line 4 of /etc/httpd/conf.d/brotli.conf:
>> Invalid command 'BrotliCompressionLevel', perhaps misspelled or defined
>> by a module not included in the server configuration
>> [alice@localhost ~]$
>>
>> Same for BrotliWindowSize if I comment out BrotliCompressionLevel.
>>
>> Comment both out and I get:
>>
>> [alice@localhost ~]$ apachectl -M
>> AH00526: Syntax error on line 19 of /etc/httpd/conf.d/brotli.conf:
>> Unknown filter provider BROTLI
>> [alice@localhost ~]$
>>
>> Help ???
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
>> For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx
>>Hi,

Have a look at https://httpd.apache.org/docs/2.4/mod/mod_brotli.html

I think that what your are looking for is BrotliCompressionQuality and BrotliCompressionWindow.

CJ

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx