Perl Tutorials - Herong's Tutorial Examples - v6.01, by Dr. Herong Yang
Perl Installation on Linux Systems
This section describes how to verify Perl installation on Linux systems. The 'perl -v' command returns which version of Perl is installed on the Linux system.
If you are running a Linux system, Perl is already installed on the system. No need to do any extra installation work.
Here is what I did to verify the Perl installation on the Linux server of my Internet service provider in 2019:
/home/herong$ which perl /usr/bin/perl /home/herong$ perl -v This is perl 5, version 26, subversion 1 (v5.26.1) built for x86_64-linux-gnu-thread-multi (with 67 registered patches, see perl -V for more detail) Copyright 1987-2017, Larry Wall Perl may be copied only under the terms of either the Artistic License or the GNU General Public License, which may be found in the Perl 5 source kit. Complete documentation for Perl, including FAQ lists, should be found on this system using "man perl" or "perldoc perl". If you have access to the Internet, point your browser at http://www.perl.org/, the Perl Home Page. /home/herong$ man perl PERL(1) Perl Programmers Reference Guide PERL(1) NAME perl - The Perl 5 language interpreter SYNOPSIS perl [ -sTtuUWX ] [ -hv ] [ -V[:configvar] ] [ -cw ] [ -d[t][:debugger] ] [ -D[number/list] ] [ -pna ] [ -Fpattern ] [ -l[octal] ] [ -0[octal/hexadecimal] ] [ -Idir ] [ -m[-]module ] [ -M[-]'module...' ] [ -f ] [ -C [number/list] ] [ -S ] [ -x[dir] ] [ -i[extension] ] [ [-e|-E] 'command' ] [ -- ] [ programfile ] [ argument ]... For more information on these options, you can run "perldoc perlrun". GETTING HELP The perldoc program gives you access to all the documentation that comes with Perl. You can get more documentation, tutorials and community support online at <http://www.perl.org/>. ...
As you can see from the output, this Linux system has Perl 5.26.1 installed and ready to use.
Even on older versions of Linux systems, Perl was included in Linux distribution packages and installed automatically. Here is an example captured on the Linux server of my Internet service provider in 2009
/home/herong$ which perl /usr/local/bin/perl /home/herong$ perl -v This is perl, v5.8.8 built for i486-linux-gnu-thread-multi Copyright 1987-2006, Larry Wall ...
Here is another example captured on my old PC running a Linux 2.0.30 system in 1999:
/home/herong$ which perl /usr/bin/perl /home/herong$ perl -v This is perl, version 5.004_03 Copyright 1987-1997, Larry Wall ...
Table of Contents