Upgrade php to 5.2 using yum

Source: Internet
Author: User
Yum upgrade php to 5.2 Method 1 -------------------------------------------------------------------------------


Vim/etc/yum. repos. d/utterramblings. repo

Input

[Utterramblings]
Name = Jason's Utter Ramblings Repo
Baseurl = http://www.jasonlitka.com/media/el?releasever/?basearch/
Enabled = 1
Gpgcheck = 1
Gpgkey = http://www.jasonlitka.com/media/RPM-GPG-KEY-jlitka


Last

Yum update php-y

Now I use this method to install it.
Php-5.2.11

Httpd-2.2.14

Method 2 -------------------------------------------------------------------------------

Yum upgrade mysql5.1 and php5.2 (disable php5.3)



Install rpmforge for yum:
Http://wiki.centos.org/AdditionalResources/Repositories/RPMForge

Yum list mysql php is found to be the latest version. it seems that the standard yum source is not updated.

Wget http://download.fedora.redhat.com/pub/epel/5/i386/epel-release-5-3.noarch.rpm
Wget http://rpms.famillecollet.com/el5.i386/remi-release-5-7.el5.remi.noarch.rpm
Rpm-Uvh remi-release-5-7.el5.remi.noarch.rpm epel-release-5-3.noarch.rpm
Yum -- enablerepo = remi list mysql

You can upgrade mysql to mysql 5.1.44-1. el5.remi.

Yum -- enablerepo = remi update mysql

I found that php needs to be upgraded to 5.3 together,
Zend optimizer currently does not support Php5.3, so you need to disable php5.3 upgrade.

Vi/etc/yum. conf

Add the last line

Exclude = php x 5.3 *

Then yum -- enablerepo = remi update mysql, you will not be able to see the php upgrade.

# Mysql-V upgraded to 5.1.44
Mysql Ver 14.14 Distrib 5.1.44, for redhat-linux-gnu (i686) using readline 5.1

Litre? After mysql 5.1.41-1 ,?? ? For:
(1 )? Original/etc/my. cnf? ,? /Etc/my. cnf. rpmnew? My. cnf
(2) litre? Table
Mysql_upgrade-p
(3) self? Repair? Table
Mysqlcheck -- all-databases -- check-upgrade -- auto-repair-p


Find a yum source with php5.2 as follows:
Http://www.webtatic.com/blog/2009/06/php-530-on-centos-5/

Rpm -- import http://repo.webtatic.com/yum/RPM-GPG-KEY-webtatic-andy
Wget-P/etc/yum. repos. d/http://repo.webtatic.com/yum/webtatic.repo
Yum -- enablerepo = webtatic list php
Php5.2 and php5.3 can be upgraded,

Upgrade php5.3 is prohibited.
Vi/etc/yum. conf
Add the last line
Exclude = php x 5.3 *

Or:
Yum -- enablerepo = webtatic -- exclude = php * 5.3 * list php

Yum -- enablerepo = webtatic -- exclude = php * 5.3 * update-y php

[Root@www.ctohome.com backup] # php-v
PHP 5.2.12 (cli) (built: Dec 17 2009 19:40:56)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies
With Zend Extension Manager v1.2.2, Copyright (c) 2003-2007, by Zend Technologies
With Zend Optimizer v3.3.3, Copyright (c) 1998-2007, by Zend Technologies

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.