突然间,我们的网站不再加载 CSS。
Chrome 浏览器控制台显示
Error 330 (net::ERR_CONTENT_DECODING_FAILED)
使用httpie工具出现类似的错误:
$ http "https://www.example.com/A.theme,,__dist,,_css,,_all.css,,q1669307021+typo3conf,,_ext,,_tiny_png,,_Resources,,_Public,,_Stylesheet,,_lightbox.css,,q1642153071+typo3conf,,_ext,,_example_theme,,_Resources,,_Public,,_Css,,_lazy-loading.css,,q1669307007+typo3conf,,_ext,,_theme,,_Resources,,_Public,,_Css,,_KeSearch,,_pagination.css,,q1642153071+typo3conf,,_ext[...],Mcc.Trdmt7Jhh6.css.pagespeed.cf.IAdiJ5fbh7.css"
HTTP/1.1 200 OK
Accept-Ranges: bytes
Cache-Control: max-age=31536000, public, no-transform
Connection: keep-alive
Content-Encoding: gzip
Content-Length: 161370
Content-Type: text/css
Date: Fri, 02 Dec 2022 10:37:04 GMT
Expires: Sat, 02 Dec 2023 10:37:04 GMT
Last-Modified: Fri, 02 Dec 2022 10:33:28 GMT
Server: nginx
Vary: Accept-Encoding
X-Content-Type-Options: nosniff
X-Original-Content-Length: 161410
X-Serve: Apache2
http: error: ContentDecodingError: ('Received response with content-encoding: gzip, but failed to decode it.', error('Error -3 while decompressing data: incorrect header check'))
我们通过以下方式解决了这个问题
sudo touch /var/cache/mod_pagespeed/cache.flush
但我们想知道这种情况是否会再次发生。
以前有人见过这样的问题吗?
页面速度版本:
# apt show mod-pagespeed-stable
Package: mod-pagespeed-stable
Version: 1.13.35.2-r0
Priority: optional
Section: httpd
Maintainer: mod_pagespeed developers <[email protected]>
Installed-Size: 22,0 MB
Pre-Depends: dpkg (>= 1.14.0)
Depends: libc6 (>= 2.17), apache2
Conflicts: mod-pagespeed-beta
Replaces: mod-pagespeed-beta
Download-Size: 8.309 kB
APT-Manual-Installed: yes
APT-Sources: http://dl.google.com/linux/mod-pagespeed/deb stable/main amd64 Packages