LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Need to update Perl on CentOS 6 (https://www.linuxquestions.org/questions/linux-software-2/need-to-update-perl-on-centos-6-a-4175512849/)

Toasterman 07-31-2014 08:26 AM

Need to update Perl on CentOS 6
 
Hello, I need to update Perl to at least 5.12 to run the latest version of ASSP properly.
http://sourceforge.net/projects/assp/

However, neither the CentOS nor the Epel repositories have anything newer than 5.10. This is causing the filter to not be able to use the Baynesian method of filtering and so most spam passes right through.

Code:

Perl version 5.012000 (5.12.0) is at least required to use the unicode Bayesian/HMM engine of ASSP 2.4.1 (14200) - you are running Perl version 5.010001 - please upgrade Perl
Is there a repository available that has 5.12 or later available? I tried the SCL repository but I don't think it's what I'm looking for since it's designed to install new versions alongside current versions. In addition, yum seemed to just ignore it despite the repo file being installed and enabled.

Code:

[root@mail yum.repos.d]# ls
CentOS-Base.repo  CentOS-Debuginfo.repo  CentOS-Media.repo  CentOS-SCL.repo  epel.repo  epel-testing.repo  oldrepos
[root@mail yum.repos.d]# yum install perl
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirror.cisp.com
 * epel: mirror.prgmr.com
 * extras: mirrors.greenmountainaccess.net
 * updates: mirror.fdcservers.net

I also attempted to install straight from a RPM file, but I got plenty of errors from this:
Code:

[root@mail /]# rpm -Uvh perl-5.12.4-24.1.x86_64.rpm
warning: perl-5.12.4-24.1.x86_64.rpm: Header V3 RSA/SHA1 Signature, key ID 9b5e3ba5: NOKEY
error: Failed dependencies:
        perl-libs = 4:5.12.4-24.1 is needed by perl-4:5.12.4-24.1.x86_64
        perl(Cwd) is needed by perl-4:5.12.4-24.1.x86_64
        perl(File::Spec) is needed by perl-4:5.12.4-24.1.x86_64
        perl(File::Spec) >= 0.8 is needed by perl-4:5.12.4-24.1.x86_64
        perl(File::Spec::Functions) is needed by perl-4:5.12.4-24.1.x86_64
        perl(File::Spec::Unix) is needed by perl-4:5.12.4-24.1.x86_64
        perl(List::Util) is needed by perl-4:5.12.4-24.1.x86_64
        perl(Scalar::Util) is needed by perl-4:5.12.4-24.1.x86_64
        perl(Scalar::Util) >= 1.10 is needed by perl-4:5.12.4-24.1.x86_64
        perl(threads) is needed by perl-4:5.12.4-24.1.x86_64
        perl(threads::shared) is needed by perl-4:5.12.4-24.1.x86_64
        perl(threads::shared) >= 1.21 is needed by perl-4:5.12.4-24.1.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) vim-enhanced-2:7.2.411-1.6.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-DBI-1.609-4.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-DBD-MySQL-4.013-3.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-URI-1.40-2.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-XML-Filter-BufferText-1.01-8.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Net-SSLeay-1.35-9.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-FreezeThaw-0.45-5.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-TimeDate-1:1.16-11.1.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-MailTools-2.04-4.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Convert-BinHex-1.119-10.1.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Text-Iconv-1.7-6.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Digest-SHA1-2.12-2.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Digest-HMAC-1.01-22.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Net-DNS-0.65-4.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-GSSAPI-0.26-5.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Authen-SASL-2.13-2.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-XML-NamespaceSupport-1.10-3.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-XML-SAX-Writer-0.50-8.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Net-LibIDN-0.12-3.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-IO-Socket-SSL-1.31-2.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-HTML-Tagset-3.20-4.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-HTML-Parser-3.64-2.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Convert-ASN1-0.22-1.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-MIME-tools-5.427-4.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-MLDBM-2.01-8.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-File-ReadBackwards-1.04-7.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Sys-Hostname-Long-1.4-5.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Net-CIDR-Lite-0.21-1.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-MIME-Types-1.28-2.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Net-SMTP-SSL-1.01-4.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Text-Glob-0.08-7.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Number-Compare-0.01-13.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Time-modules-2006.0814-5.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-libwww-perl-5.833-2.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-JSON-2.15-5.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Email-Address-1.889-3.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Email-MessageID-1.401-4.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Email-MIME-Encodings-1.313-2.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Crypt-OpenSSL-Random-0.04-9.1.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Email-Date-Format-1.002-5.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-NetAddr-IP-4.027-7.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Crypt-OpenSSL-Bignum-0.04-8.1.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Crypt-OpenSSL-RSA-0.25-10.1.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Email-MIME-ContentType-1.015-2.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-MIME-Charset-1.006.2-3.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Class-Factory-Util-1.7-5.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Error-1:0.17015-4.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Return-Value-1.666001-1.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Email-Send-2.198-1.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Mail-SPF-2.8.0-2.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Unicode-LineBreak-2011.11-2.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Mail-DKIM-0.37-2.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Lingua-Stem-Snowball-0.952-4.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Sys-MemInfo-0.91-5.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Net-IP-1.25-13.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-LDAP-1:0.40-1.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Crypt-OpenSSL-AES-0.02-9.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-CPAN-Meta-YAML-0.008-13.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Archive-Zip-1.30-2.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Net-IP-Match-Regexp-1.01-1.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Tie-DBI-1.05-1.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Text-Unidecode-0.04-7.1.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Crypt-CBC-2.29-3.el6.noarch
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-BerkeleyDB-0.43-3.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) net-snmp-libs-1:5.5-49.el6_5.1.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-Socket6-0.23-4.el6.x86_64
        perl(:MODULE_COMPAT_5.10.1) is needed by (installed) perl-IO-Socket-INET6-2.56-4.el6.noarch
        perl(Cwd) is needed by (installed) perl-DBI-1.609-4.el6.x86_64
        perl(Cwd) is needed by (installed) perl-Pod-Simple-1:3.13-136.el6.x86_64
        perl(Cwd) is needed by (installed) perl-ExtUtils-ParseXS-1:2.2003.0-136.el6.x86_64
        perl(Cwd) is needed by (installed) perl-ExtUtils-MakeMaker-0:6.55-136.el6.x86_64
        perl(Cwd) is needed by (installed) perl-Archive-Tar-0:1.58-136.el6.x86_64
        perl(Cwd) is needed by (installed) perl-Archive-Extract-1:0.38-136.el6.x86_64
        perl(Cwd) is needed by (installed) perl-ExtUtils-CBuilder-1:0.27-136.el6.x86_64
        perl(Cwd) is needed by (installed) perl-Archive-Zip-1.30-2.el6.noarch
        perl(File::Spec) is needed by (installed) perl-DBI-1.609-4.el6.x86_64
        perl(File::Spec) is needed by (installed) perl-MIME-tools-5.427-4.el6.noarch
        perl(File::Spec) is needed by (installed) perl-Email-Valid-0.184-1.el6.rf.noarch
        perl(File::Spec) is needed by (installed) perl-Convert-TNEF-0.18-1.el6.rf.noarch
        perl(File::Spec) is needed by (installed) perl-Pod-Simple-1:3.13-136.el6.x86_64
        perl(File::Spec) is needed by (installed) perl-Test-Harness-0:3.17-136.el6.x86_64
        perl(File::Spec) is needed by (installed) perl-ExtUtils-ParseXS-1:2.2003.0-136.el6.x86_64
        perl(File::Spec) is needed by (installed) perl-ExtUtils-MakeMaker-0:6.55-136.el6.x86_64
        perl(File::Spec) is needed by (installed) perl-devel-4:5.10.1-136.el6.x86_64
        perl(File::Spec) is needed by (installed) perl-Module-Load-1:0.16-136.el6.x86_64
        perl(File::Spec) is needed by (installed) perl-Module-Load-Conditional-0:0.30-136.el6.x86_64
        perl(File::Spec) is needed by (installed) perl-IPC-Cmd-1:0.56-136.el6.x86_64
        perl(File::Spec) is needed by (installed) perl-Archive-Tar-0:1.58-136.el6.x86_64
        perl(File::Spec) is needed by (installed) perl-Email-Send-2.198-1.el6.noarch
        perl(File::Spec) is needed by (installed) perl-Archive-Extract-1:0.38-136.el6.x86_64
        perl(File::Spec) is needed by (installed) perl-ExtUtils-CBuilder-1:0.27-136.el6.x86_64
        perl(File::Spec) is needed by (installed) perl-Archive-Zip-1.30-2.el6.noarch
        perl(File::Spec::Functions) is needed by (installed) perl-Module-Pluggable-1:3.90-136.el6.x86_64
        perl(File::Spec::Functions) is needed by (installed) perl-ExtUtils-CBuilder-1:0.27-136.el6.x86_64
        perl(File::Spec::Unix) is needed by (installed) perl-Archive-Tar-0:1.58-136.el6.x86_64
        perl(List::Util) is needed by (installed) perl-IO-Compress-Base-0:2.021-136.el6.x86_64
        perl(Scalar::Util) is needed by (installed) perl-IO-Compress-Base-0:2.021-136.el6.x86_64
        perl(Scalar::Util) is needed by (installed) perl-Compress-Zlib-0:2.021-136.el6.x86_64
        perl(Scalar::Util) is needed by (installed) perl-JSON-2.15-5.el6.noarch
        perl(Scalar::Util) is needed by (installed) perl-Error-1:0.17015-4.el6.noarch
        perl(Scalar::Util) is needed by (installed) perl-Email-Send-2.198-1.el6.noarch
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Pod-Escapes-1:1.04-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-version-3:0.77-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-libs-4:5.10.1-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Pod-Simple-1:3.13-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Module-Pluggable-1:3.90-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Compress-Raw-Zlib-1:2.021-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Digest-SHA-1:5.47-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Time-HiRes-4:1.9721-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Test-Harness-0:3.17-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-ExtUtils-ParseXS-1:2.2003.0-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-ExtUtils-MakeMaker-0:6.55-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-devel-4:5.10.1-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-IO-Compress-Base-0:2.021-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-IO-Compress-Zlib-0:2.021-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Compress-Zlib-0:2.021-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Locale-Maketext-Simple-1:0.18-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Params-Check-1:0.26-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Test-Simple-0:0.92-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Module-Load-1:0.16-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Module-Load-Conditional-0:0.30-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-IPC-Cmd-1:0.56-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-IO-Zlib-1:1.09-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Package-Constants-1:0.02-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Archive-Tar-0:1.58-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-Archive-Extract-1:0.38-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-IO-Compress-Bzip2-0:2.021-136.el6.x86_64
        perl = 4:5.10.1-136.el6 is needed by (installed) perl-ExtUtils-CBuilder-1:0.27-136.el6.x86_64

Thanks in advance.

szboardstretcher 07-31-2014 08:32 AM

You can use "Perlbrew" which is sort of like "rvm" for ruby. Remember to test this on a VM or something first, so you can OK the changes to your prod system.

Here is the site: http://perlbrew.pl/

and here are some examples:

Code:

#Install
perlbrew install perl-5.12.2
perlbrew install perl-5.13.6

#List installed versions
perlbrew list

#Use a particular version
perlbrew switch perl-5.12.2
perl -v


smallpond 07-31-2014 08:36 AM

I believe CentOS 7 has Perl 5.16.

Toasterman 07-31-2014 09:04 AM

Quote:

Originally Posted by szboardstretcher (Post 5212509)
You can use "Perlbrew" which is sort of like "rvm" for ruby. Remember to test this on a VM or something first, so you can OK the changes to your prod system.

Here is the site: http://perlbrew.pl/

and here are some examples:

Code:

#Install
perlbrew install perl-5.12.2
perlbrew install perl-5.13.6

#List installed versions
perlbrew list

#Use a particular version
perlbrew switch perl-5.12.2
perl -v



Thank you! That looks useful. One of the instructions says:
Code:

Append the following piece of code to the end of your ~/.bash_profile and start a
new shell, perlbrew should be up and fully functional from there:

    source ~/perl5/perlbrew/etc/bashrc

I don't see a ~/.bash_profile file though

szboardstretcher 07-31-2014 09:05 AM

what is the output of:

Code:

whoami
cd ~
ls -alh


Toasterman 07-31-2014 09:16 AM

Nevermind I do see it.
One question I have about perlbrew is the dependencies. Can it update them too?
What about the modules?

EDIT:
I added source ~/perl5/perlbrew/etc/bashrc to that file but it doesn't seem to be doing anything.
EDIT2:
I just had to log out and in again. That was easy.

szboardstretcher 07-31-2014 09:26 AM

Plenty of information out there about installing it on Centos 6. https://www.google.com/search?q=perlbrew+centos+6

Or if you find that perlbrew doesn't work, there is one in cpan called.. perlall which does the same thing. http://search.cpan.org/~rurban/App-p...script/perlall

Toasterman 07-31-2014 12:17 PM

One last thing:
I can't find this but how can I remove perlbrew and go back to the system Perl if needed?
I know the binary is at /usr/bin/perl, but perl goes to the perlbrew installation.
EDIT2:
Nevermind, I found it. I just have to remove that one line out of .bash_profile.


All times are GMT -5. The time now is 06:48 AM.