Cpanel: Undefined subroutine &Compress::Zlib::gzopen

On a particular Cpanel box I occasionally receive the following when attempting to install or update any Perl module — whether initiated by myself or by Cpanel:

Undefined subroutine &Compress::Zlib::gzopen

The fix is to remove all traces of Compress:Zlib with the following command:

rm -rf `find /usr/lib/perl5/ | grep Compress | grep Zlib`

When this happens, it’s likely the Perl modules have become out of sync, so after running the previous command be sure to update everything:

/scripts/checkperlmodules --full

Comments are closed.