Which CentOS/RedHat Repo to use for php 5.6+? - php

All of our webservers are running CentOS 7. We now have some cases where the PHP 5.4.4+, which is the lastest version provided in the official CentOS & EPEL repositories, is not enough anymore. Meaning we have to upgrade PHP to at least PHP version 5.6. What is the most elegant and stable way to do so?
There are various repositories like Webtactic which would offer PHP version 5.6 but in the Official CentOS Repo list Webtactic is listed in the section "Known Problem Repositories". Furthermore compiling php on CentOS is a mess concerning the upgrades...
What would you recommend?
Cheers

Related

Install specific PHP version on Ubuntu 16.04 server

I need a bit of help. I have AWS EC2 server running on Ubuntu 16.04. My question is how do I install specific PHP version 7.3.12 ?
I have installed PHP and it ended in 7.3.14. Is this gonna be an issue if I have local environment with PHP 7.3.12 ? And how do we specifically install 7.3.12 on ubuntu server?
Many thanks for your help.
You will not have any issue between PHP 7.3.12 and 7.3.14.
A version is split in 3 parts, 7(for main version).3(for current minor version).12(for bugfixes).
Do not try to exec php code on two differents main version 5.0 / 7.0 because of many big changes.
Also there is no many changes in minor version but still, you can have some differents behavior.
And the last one for bugfixes, you should not worry about.
For a complete list of change you can find the changelog : https://www.php.net/ChangeLog-7.php#PHP_7_3
Bugfixes version are release all life of supported version, for exemple PHP 7.3 will have security fixes until 6 Dec 2021.
For actual list, see : https://www.php.net/supported-versions.php
For your other question, you can install another version of php with major an minor (like php 7.2 or php 7.3) in ubuntu and change the path of the php exec command.
But you can't choose (Not sure at 100%) between php 7.3.12 and 7.3.14 because it's bugfixes and it's just a update.

Is the official release of php 7 in CentOS released?

In this 2 years old tutorial (https://www.digitalocean.com/community/tutorials/how-to-upgrade-to-php-7-on-centos-7) they said
Since PHP 7.x is not yet packaged in official repositories for the major distributions, we'll have to rely on a third-party source.
But, In the centos wiki they talked about official release as I guessed. But I am bit confused whether it is official release or not. Although I follow the wiki instruction but my php don't upgraded(I cann't upgrade php 5.4 to 7 in centos server).
You will have to remove 5.x and install 7.x with yum - it cannot be updated.
For 7.2 you have to enable a special repository.
https://www.cyberciti.biz/faq/how-to-install-php-7-2-on-centos-7-rhel-7/

install old php extension ubuntu 14.04

I want to install the phpmotion on Ubuntu 14.04. I need to use it for php 5.3, and older. I did the PHP installation package but I can not attach extensions. How can I do?
I'm unsure how to get an old copy of PHP 5.3 except from compiling it yourself; it's past end of life so you might be better off finding a newer library than risking the security of your entire application.
The Ondřej Surý PHP 5.4 repo is your best bet to get an older version, though it's one ahead of the version you suggest.

Downgrade to PHP 5.4 on Arch Linux

I am running a fully updated Manjaro (Arch Linux derivative) distribution with PHP 5.5.6 installed using pacman.
Some scripts I am forced to develop with are not fully compatible with PHP 5.5 yet.
Is there an easy way to downgrade to PHP 5.4 or do I have to compile it from source?
Yes it's possible to downgrade packages. Short version of possibilities:
Look in the pacman cache of your computer if the packages are still present (/var/cache/pacman/pkg)
Get old packages from the Arch Rollback Machine
Build the old packages from ABS
The procedures are explained in the wiki. The simplest one will certainly be to look in the cache, or eventually ARM if they are not present.

Php 5 on RedHat Enterprise Linux 5

By default, RHEL5.x64 comes with 5.1.6 - pretty old. I'm looking for a more up to date version, 5.2.8, or even the latest 5.2.9 (as of March 2009). Ideally, a Yum/RPM-based solution, for transparent upgrades (when I plan).
How do you upgrade the default for an up-to-date version?
Oracle have some up-to-date PHP RPMs, but not in a repository that I can see. You could try asking Christopher Jones if he would be interested in building repository metadata for them?
There are also versions in the CentOS testing repository, and Remi Collet has PHP 5.2.9 in his repository (read his announcement).
you could also install a fedora RPM package for PHP in redhat enterprise. RHEL5 rpm packages are like fedora core 6 packages. something like this.
I have installed many Fedora Core 6 RPM packages on RHEL 5 without any problems.
I suggest getting the spec file for the Red Hat PHP rpm, then use that to create your own RPM, in your own local repo, and use that. This way you get the benefits of the newest PHP, configured to be as compatible as possible with your system, and when using YUM for other things, that require PHP, they will be satisfied with your install.
I've elected to go for the Zend-CE solution, installed with YUM (default on rhel5). It's not perfect, the admin-dashboard security leaves something to be desired, and enabling it to be used for php-cli needs at least a manual removale of the old php-cli package + a symlink to the new, but otherwise, its not complicated.
please look at:
http://bluhaloit.wordpress.com/2008/03/13/installing-php-52x-on-redhat-es5-centos-5-etc/
it'll up2date your php for 5.3
[]'

Categories