Upgrading php in Linux

Farhat asked:

I am running a Redhat on a webserver. The current version of php on the server is 5.1.6. I want to upgrade it to 5.3.8 so I downloaded php and compiled it and replaced the older php binary with the newer one. I then restarted the httpd daemon. When I type php -v on the command line it gives me 5.3.8 but when I look at php on the browser using <?phpinfo();?> I get 5.1.6. How can I resolve this?


My answer:

Many of us use the remi repository to keep current with PHP and MySQL. It will currently give you PHP 5.4 and MySQL 5.5 on EL5 and EL6. All you need to do is install the remi-release RPM and then yum upgrade.

View the full question and answer on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.