PHP5 on CentOS
Posted by Quinn at July 10th, 2007 12:40pm under web 1 Comment Permalink
I had some fun playing with CentOS4. I am kind of new to rpm and yum, so I thought I should make some notes.
It is time to go PHP5. I am so happy to see the movement. Unfortunately, I had a box of CentOS4 came with PHP4 installed. Yes, I was obsessed to make a change to the box.
I had to install yum first. I had to get some dependencies as well, so here is what I did.
#wget http://mirror.centos.org/centos-4/4/os/i386/CentOS/RPMS/sqlite-3.3.6-2.i386.rpm #wget http://mirror.centos.org/centos-4/4/os/i386/CentOS/RPMS/python-sqlite-1.1.7-1.2.1.i386.rpm #wget http://mirror.centos.org/centos-4/4/os/i386/CentOS/RPMS/python-elementtree-1.2.6-5.el4.centos.i386.rpm #wget http://mirror.centos.org/centos-4/4/os/i386/CentOS/RPMS/python-urlgrabber-2.9.8-2.noarch.rpm #wget http://mirror.centos.org/centos-4/4/os/i386/CentOS/RPMS/yum-2.4.3-3.el4.centos.noarch.rpm # rpm -ivh sqlite-3.3.6-2.i386.rpm # rpm -ivh python-sqlite-1.1.7-1.2.1.i386.rpm # rpm -ivh python-elementtree-1.2.6-5.el4.centos.i386.rpm # rpm -ivh python-urlgrabber-2.9.8-2.noarch.rpm # rpm -ivh yum-2.4.3-3.el4.centos.noarch.rpm
Now yum is ready. But, when I went..
# yum update --enablerepo=centosplus php
I got errors of dependency conflicts. Then, I found this, which explains the issue of upgrading to PHP5 with yum.
Here was the solution.
# vi /etc/yum.repos.d/CentOS-Base.repo [base] exclude=php* kernel* postfix* [update] exclude=php* kernel* postfix* [centosplus] exclude=php-xml php-domxml
I am not sure if this one above actually helped. But removing php-domxml like below was a MUST. Then, it came through.
# rpm -e --nodeps php-domxml # yum update --enablerepo=centosplus mysql php
This upgraded all MySQL and PostgreSQL as well. If the server was hosting real websites, I should to be more careful though. Anyway, I then added some of those and I'm happy now.
http://centos.arcticnetwork.ca/4/centosplus/i386/RPMS/php-xml-5.1.6-3.el4s1.7.i386.rpm http://centos.arcticnetwork.ca/4/centosplus/i386/RPMS/php-xmlrpc-5.1.6-3.el4s1.7.i386.rpm
James said (August 8th, 2007 4:32pm)











