Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to find out what version of mod_perl is installed?

Tags:

perl

apache2

In order to debug my perl code I need to find out what version of mod_perl is installed.

How do I find out the version of mod_perl I have installed?

like image 951
Thariama Avatar asked May 21 '13 11:05

Thariama


People also ask

How to get the version of a module in Perl?

VERSION is a UNIVERSAL method of all Perl classes. You can use it to get the module version (if it has been set which it usually has). Here is a one liner where you only have to add the module name once: perl -le 'eval "require $ARGV " and print $ARGV ->VERSION' Some::Module

What version of mod_perl do I have installed?

confirms that you have mod_perl installed and its version is 1.21. However, just because you have got mod_perl linked in there, that does not mean that you have configured your server to handle Perl scripts with mod_perl. You will find configuration assistance at ModPerlConfiguration

How do I find the version of a Perl interpreter?

You can use $PERL_VERSION or $^V too as the revision, version, and subversion of the Perl interpreter, represented as a “version” object. This variable first appeared in perl version 5.6.0; earlier versions of perl will see an undefined value.

How to check Perl version of your hosting provider?

If your web hosting provider don’t provide access to a shell, use the following perl program to find out perl version: #!/usr/bin/perl # Available under BSD License.


2 Answers

Try:

perl -Mmod_perl\ 999

If that doesn't work, try:

perl -Mmod_perl2\ 999

The first checks for mod_perl, version 999. Since that doesn't exist, it will output the actual version you have installed or an error saying it can't be found in the @INC. The second does the same thing, but for mod_perl2.

Example output for me:

> perl -Mmod_perl2\ 999

mod_perl2 version 999 required--this is only version 2.000005. BEGIN failed--compilation aborted.

like image 176
gpojd Avatar answered Sep 23 '22 21:09

gpojd


In general:

perl -Mmod_perl -E 'say $mod_perl::VERSION'
like image 37
JRFerguson Avatar answered Sep 23 '22 21:09

JRFerguson