How to upgrade the default Perl version in Linux

Source: Internet
Author: User
How to upgrade the default Perl version in Linux

16:42:00 | category:

Linux | font size subscription

We do not recommend RM first.
First download tar.gz... and then manually install .. default to the/usr/local/directory ..
Then modify the symbolic link of/usr/bin/perl to/usr/local/bin/Perl.

The local system is centos4.5. try the latest version.
:
[Url] http://www.cpan.org/src/readme.html#/url]
Download link:
[Url] http://www.cpan.org/src/perl-5.10.0.tar.gz#/url]
The download method does not need to be mentioned. I am used to wget. So wget [url] http://www.cpan.org/src/perl-5.10.0.tar.gz#/url].
Decompress and install
# Tar zxvf perl-5.10.0.tar.gz
# Cd perl-5.10.0
#./Configure-des-dprefix =/usr/local/perl
Parameter-dprefix: Specify the installation directory as/usr/local/Perl.
# Make
# Make Test
# Make install
If this process is correct, congratulations on the installation. Is it very easy?
Next we will replace the original Perl of the system. If we have the latest version, we will use it.
# Mv/usr/bin/perl. Bak
# Ln-S/usr/local/perl/bin/perl/usr/bin/perl
# Perl-V

This is Perl, v5.10.0 built for i686-linux

Copyright 1987-2007, Larry Wall

Perl may be copied only under the terms of either the artisticlicense or
GNU General Public License, which may be found in the Perl 5 sourcekit.

Complete documentation for Perl, including FAQ lists, shocould befound on
This system using "Man Perl" or "perldoc Perl". If you have accessto
Internet, point your browser at [url] http://www.perl.org/#/url#, the Perl home page.

Well, if your execution of Perl-V is the same as my prompt, the installation is successful.
Then you can use it to install some other Perl modules you need.
# Perl-mcpan-e Shell
If you run the command for the first time, you will be prompted to install CPAN and require the connection network to download the latest module list. Then you can install the module.
CPAN [1]> install DBI
Is it easy?

Now the problem arises. How can I uninstall it? I tried to make Uninstall. It doesn't work.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.