How To Install perl-CPAN on AlmaLinux 8

In this tutorial we learn how to install perl-CPAN in AlmaLinux 8. perl-CPAN is Query, download and build perl modules from CPAN sites

Introduction

In this tutorial we learn how to install perl-CPAN on AlmaLinux 8.

What is perl-CPAN

The CPAN module automates or at least simplifies the make and install of perl modules and extensions. It includes some primitive searching capabilities and knows how to use LWP, HTTP external download clients to fetch distributions from the net.

We can use yum or dnf to install perl-CPAN on AlmaLinux 8. In this tutorial we discuss both methods but you only need to choose one of method to install perl-CPAN.

Install perl-CPAN on AlmaLinux 8 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install perl-CPAN using dnf by running the following command:

sudo dnf -y install perl-CPAN

Install perl-CPAN on AlmaLinux 8 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install perl-CPAN using yum by running the following command:

sudo yum -y install perl-CPAN

How To Uninstall perl-CPAN on AlmaLinux 8

To uninstall only the perl-CPAN package we can use the following command:

sudo dnf remove perl-CPAN

References

Summary

In this tutorial we learn how to install perl-CPAN on AlmaLinux 8 using yum and dnf.