I am very new to Linux world, sorry if this question been posted here.

I just installed CentOS 5.5 x86_64. PHP 5.1.6 was installed.

However my application requires PHP5.3

I then run command: "yum update php", nothing happened. Seems 5.1.6 is the latest in yum.

So how may I update to php 5.3?


If you can wait, CentOS 5.6 should have native PHP53 since upstream RHEL 5.6 now ships PHP53.

If you can't wait then this might help you install the packages from the REMI repo:

yum remove mysql php* (if currently have PHP 5.1.x and/or mysql installed)

rpm -Uvh http://download.fedora.redhat.com/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm

rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-5.rpm

yum --enablerepo=remi install php

Getting the mysql commandline client on the box is tricky:

yum --enablerepo=remi --disablerepo=updates --disablerepo=base install mysql



Edit: If your MySQL server is on the same box this procedure has the unfortunate consequence of having you run the MySQL Server from the REMI repo. i.e. You're basically in dependency hell.


If the packages for any given distribution are out of date and you can't wait for the package maintainers to release newer versions, you'll have no choice but to compile from source yourself or look for someone else who's already done so and take a chance at installing their binary (I don't recommend this; especially in a production environment).

I just did a quick Google and found someone had already compiled from source and made a package available if you wanted to test.


  • Hi Sean, thanks for the recommendation! I just found there is a recommended source mentioned at wiki.centos.org/AdditionalResources/Repositories It says: "Remi Collet maintains latest version of MySQL and PHP (backports of fedora RPM). Repo configs for EL5 i386 and x86_64 as well as EL4 are available. ". I then go his site: rpms.famillecollet.com but which file to download and what command to execute? Sorry for asking so much, have no idea how to manage the rpm stuff. – gilzero Mar 29 '11 at 19:27
  • rpms.famillecollet.com/enterprise/5 The packages under there are for CentOS 5. It's been awhile since I've used RPM, but I'm pretty sure the standard installation is rpm -Uvh {packageName}. You might want to check the rpm docs though. – Sean C. Mar 29 '11 at 19:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.