The script checkperlmodules is used on cPanel servers to manage a set list of perl CPAN modules. These modules are used by cPanel scripts, applications like SpamAssassin and to provide a nice set of modules for perl web developers. During each run of scripts/upcp, checkperlmodules is executed. If any modules were updated on the CPAN mirror, then the local installation will be updated.
There are quite a few problems with this tack, some of which will change in cPanel version 11.34. CPAN moduels have no quality guarantees. They also have poor standards as far as dependency definition and resolution.
When using cPanel on a Debian system it makes sense to use the Perl distribution provided by Debian, especially the CPAN modules. This allows you to benefit from the more stringent standards of Debian and it’s community. Also it allows you to use a newer version of perl then the standard provided by cPanel. Debian currently provides version 5.10.1 while the cPanel Perl installer gives you 5.8.8. How though does one disable the behavior of checkperlmodules?
It’s quite simple actually. The checkperlmodules script builds a list of CPAN modules to check and install. It then refines this list according to a custom black list you can create. This black list is the file /var/cpanel/perl_module_update_exclude. To blacklist a module, add the module name to the file. Each module must be on it’s own line.
Here is the contents of my perl_module_update_exclude:
CDB_File DB_File HTTP::Date Scalar::Util MIME::Base64 URI Net::FTP HTML::Tagset HTML::Parser HTML::HeadParser LWP Bundle::LWP DBI Data::ShowTable Mysql DBD::mysql Bundle::DBD::mysql Crypt::SSLeay CPAN::SQLite Data::Dumper Digest::MD5 Digest::SHA1 Encode ExtUtils::Constant ExtUtils::ParseXS File::Touch Filesys::Df Filesys::Virtual Filter::Util::Call Getopt::Long Getopt::Param::Tiny Compress::Raw::Zlib Authen::Libwrap Net::FTPSSL Net::SSL Net::SSLeay IO::Compress::Gzip IO::Scalar IO::Socket::SSL IO::Stty IO::Uncompress::Gunzip Lchown List::Util MD5 Net::DNS Net::OSCAR Pod::Perldoc Storable Sys::Syslog Term::ReadKey Term::ReadLine::Perl Time::HiRes Tree::MultiNode Unix::PID Unix::PID::Tiny XML::LibXML::Common XML::LibXML XML::Parser XML::SAX XML::Simple lib::restrict YAML::Syck Crypt::Passwd::XS Crypt::GPG Class::Accessor Class::Accessor::Fast File::MMagic::XS Email::Valid File::ReadBackwards ExtUtils::MakeMaker Mail::SRS Acme::Spork Archive::Tar Archive::Tar::Streamed Archive::Zip Encode::Guess MIME::Lite Business::OnlinePayment::AuthorizeNet Business::UPS CGI Class::Std::Utils Compress::Bzip2 Compress::Zlib DBIx::MyParsePP DBD::SQLite2 Date::Parse File::Tail GD::Graph GD::Text::Align Memoize Geo::IPfree HTML::Parser HTTP::Daemon::App IO::Socket::ByteCounter Image::Size MIME::Base64 Mail::DomainKeys Error NetAddr::IP Net::DNS::Resolver::Programmable Mail::SPF Mail::SPF::Query Mail::DKIM IP::Country Graph::Easy Graph::Flowchart Mail::SpamAssassin URI::Escape File::Find::Rule::Filesys::Virtual File::Slurp Net::DAV::Server Net::Daemon Net::Daemon::SSL Net::LDAP Net::LDAP::Schema Net::LDAP::Server Net::Daemon Net::Daemon::SSL Net::LDAP Net::LDAP::Schema Net::LDAP::Server Net::IP::Match::Regexp OLE::Storage_Lite GD::Graph Parse::RecDescent Quota SVG::TT::Graph Safe::Hole Text::CSV Spreadsheet::ParseExcel Spreadsheet::WriteExcel String::CRC32 SQL::Statement Set::Crontab Tie::IxHash Tie::ShadowHash Tie::DBI URI::URL Bundle::Interchange version Encode::Locale Curses::UI XML::SAX::Expat Locales ExtUtils::Install Filesys::Statvfs Devel::PPPort Linux::Inotify2
With that list in place, you can install those modules via apt and not worry about checkperlmodules. Each time checkperlmodules runs it will skip all the modules you blacklisted.
Is this safe? Well cPanel doesn’t modify those modules. Most of the them are installed directly fro CPAN. cPanel scripts don’t rely on specific versions of the modules. Occassionally cPanel will effect a “holdback” wherein a module is not allowed to update beyond a specific version. This is done to prevent problems in a CPAN module from causing problems on a cPanel & WHM server. As of cPanel & WHM version 11.30 though, all holdbacks were removed.
Note: cPanel & WHM version 11.34 will deliver perl 5.14, a tremendous step up in the perl world.
No related posts.
Related posts brought to you by Yet Another Related Posts Plugin.
