Skip to main content
Perl Modules installs CPAN modules into your account’s local Perl tree, no SSH required. Useful when running Perl CGI scripts, mailing list software, or one-off cron jobs.
Perl Modules with installed list and search

Install a module

1

Search the catalog

Type the module name (e.g., DBI, LWP::Simple, Email::MIME). cPanel queries CPAN and shows matches.
2

Click Install next to the module

The module and its dependencies are compiled and dropped into ~/perl/.Compilation can take a few seconds for small modules and a couple of minutes for things like DBD::mysql that pull in C dependencies.
3

Use it from your Perl script

The cPanel Perl wrapper adds ~/perl/lib/perl5/ to @INC automatically when you run scripts via the cPanel-managed shebang. If you’re running scripts another way, add it yourself:
use lib "$ENV{HOME}/perl/lib/perl5";
use DBI;

Update or uninstall

Both options sit next to Install in the installed-modules list. Same caveats as install: updates rebuild the module against the active Perl version; uninstall removes the files and any dependents that are now orphaned.

When to use this vs cpanm

This tool wraps cpanm (cpanminus) under the hood. Anything you can install here you can also install over SSH:
cpanm --local-lib=~/perl Email::MIME
Use the cPanel UI when:
  • You don’t have SSH on your plan.
  • You want a one-off install and the click is faster than typing the command.
Use SSH cpanm when:
  • You’re scripting an install (deploy hooks, automated setup).
  • You need a specific version: cpanm Module@1.234.
  • The cPanel UI times out on a slow-compiling module (rare, but DBD::Pg and Crypt::OpenSSL::* are known offenders).

Common issues

The module needs a C library that isn’t installed. Most XS-based modules need libssl-dev, libxml2-dev, or similar at compile time. We install the most common ones server-wide; for an unusual one, open a ticket and we can install the dev package.
The script isn’t loading the local Perl tree. Add the use lib line above, or shebang to /usr/local/cpanel/3rdparty/bin/perl which has the wrapper baked in.
DBD::mysql needs network access to the MySQL test server during build. Ours is firewalled in some configs. If the install hangs past 5 minutes, kill the cPanel page and re-run with --notest over SSH:
cpanm --notest --local-lib=~/perl DBD::mysql

Need a hand?