How to find out what version of mod_perl is installed?

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.


In general:

perl -Mmod_perl -E 'say $mod_perl::VERSION'

For me above solutions didn't work. This, however, worked fine:

rpm -q mod_perl

Tags:

Perl

Apache2