• I’m trying to understand a “bug” that’s causing my some grief and why it exists. Essentially, we have enabled zlib compression on a dedicated server running Apache. As a result, when updating plugins/themes, it doesn’t complete properly in the UI while continuing in the background. A bug was opened 7 years ago and then re-opened 7 days ago. The only “solution” provided just hides the error from the logs. Alternatively, turning off zlib compression fixes the issue. We’ve discussed this issue with our hosting provider and with cPanel and both are blaming this on WordPress. I’m stuck in the middle. I like zlib compression, so I don’t want to turn it off, but we’ve come across a few plugins that don’t re-activate because of this and that’s not good. Any help would be appreciated.

    Bug
    https://core.trac.wordpress.org/ticket/18525

    Similar Post
    https://wordpress.org/support/topic/dashboard-update-process-does-not-complete/

Viewing 1 replies (of 1 total)
  • Dion

    (@diondesigns)

    zlib.output_compression should always be turned off in PHP because it conflicts with output buffering.

    If you want output compression, you should instead turn it on in Apache, where you have a choice of gzip or (if your server supports it) brotli compression. It should only be enabled for specific types of content, for example:

    <FilesMatch "\.(js|css|svg|html|htm|xml|json|php)$">
    	SetOutputFilter DEFLATE
    </FilesMatch>

    The above would enable gzip compression when serving files with specific extensions. It can be added to a .htaccess file, but since you said you have a dedicated server, it would be better to set this in the global httpd.conf file.

Viewing 1 replies (of 1 total)

The topic ‘zlib Compression & Updates’ is closed to new replies.