CentOS6.6 + Postfixadmin 2.3rc5 + PHP5.3, upgrade to PHP5.4

big_bum asked:

We’re running PHP5.3.8 on a CentOS6.6 mailserver with Postfixadmin 2.3rc5.
The client only wanted a mailserver at first, but then wanted to move some other sites to this server.
Some of the sites need PHP5.4 to run, but we’re afraid that upgrading from PHP5.3 to PHP5.4 will break our Postfixadmin installation. (We found some info that postfixadmin is compatible with php5.4 from version 2.3.5)
Also, upgrading Postfixadmin will likely break the database and we can’t afford downtime.

What is the best approach to this issue? Multiple PHP versions? Has anyone upgraded such an old postfixadmin version to a new one?
Has anyone succesfully installed php5.4 with an older version of Postfixadmin?

My answer:


My go-to for PHP on CentOS is the remi repository. Remi is a Red Hat employee who also packages the official Red Hat PHP packages, in addition to his own repos where he maintains compatible packages which are more current versions. Simply installing and enabling the remi repository on CentOS 6 and then yum updating is sufficient to upgrade to PHP 5.4. (The repos ship disabled by default and you need to explicitly enable them.) You can also enable PHP 5.5 or 5.6, and probably should do so since 5.4 will be EOL soon, and almost all packages that work on 5.4 will also work on 5.5 or later.

For compatibility, I would just go ahead and upgrade Postfixadmin and PHP at the same time. You’ll need a short maintenance period (five minutes or less?) or a slightly longer period if you need to do database schema changes and have a large database (you likely don’t). The Postfixadmin web site says that loading upgrade.php after the upgrade is sufficient.

Remember your backups.


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.