在我的系统中,有CentOS 5和PHP 5.1.6。 我试图更新PHP版本(5.3)
yum update php result: No Packages marked for Update
任何人有任何build议? 谢谢!
对于CentOS版本4,
wget http://download.fedora.redhat.com/pub/epel/4/i386/epel-release-4-10.noarch.rpm wget http://rpms.famillecollet.com/el4.i386/remi-release-4-7.el4.remi.noarch.rpm rpm -Uvh remi-release-4*.rpm epel-release-4*.rpm cd /etc/yum.repos.d wget http://rpms.famillecollet.com/remi-enterprise.repo rpm --import http://rpms.famillecollet.com/RPM-GPG-KEY-remi yum --enablerepo=remi list php php.i386 5.3.2-1.el4.remi yum --enablerepo=remi update php
我在两个不同的系统(CentOS 5.4和4.7)中升级了PHP 5.3.4。
我试过以下选项成功更新PHP 5.3.4!
对于CentOS 5.4
rpm --import http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5
webtatic RPM安装
rpm -Uvh http://repo.webtatic.com/yum/centos/5/latest.rpm
PHP安装
yum --enablerepo=webtatic install php
PHP更新
yum --enablerepo=webtatic update php
纯粹的巧合,我刚刚写了另一个问题。 我知道这似乎是更新MySQL,但它应该强制PHP更新,并避免依赖性问题。 如果PHP没有按照以下所有步骤安装,yum删除php,然后运行:yum –enablerepo = remi install php(以及其他任何你需要的)
按照您自己的风险等:
注意:对于64位CentOS For 32位,不要使用.x86_64后缀
yum remove mysql mysql-server su -c 'rpm -Uvh http://download.fedora.redhat.com/pub/epel/5/i386/epel-release-5-4.noarch.rpm' wget http://rpms.famillecollet.com/enterprise/remi-release-5.rpm rpm -Uvh remi-release-5*.rpm yum --enablerepo=remi install mysql.x86_64 mysql-server.x86_64
你可能需要添加你需要的最后的yum命令 – 例如:php-mysql php-devel php-pdo
在CentOS 5.6(和其他,大概),你可以:
yum install php53
如果这给你带来麻烦,你可能首先必须
yum erase php5