On 12/14/2021 9:38 AM, TE Dukes wrote:> Been trying to get multiple versions of PHP on a CentOS 7 machine, off and > on for the past couple months. I have followed 5 or 6 different howtos but > none work. They are very similar and they seems to be done on a fresh > install as most do an apache install is the steps. I setup two virtualhosts > one for PHP5.6 and one for PHP 7.4. When I create a file with phpinfo, it > reports back 5.6.xxx on both sites.You should be using Software Collections to install additional versions: https://www.softwarecollections.org/en/about/ Instead of running PHP within the Apache binary, use a proxy. I suggest learning how to use fcgi. Your VirtualHost could include a directive like this: SetHandler "proxy:fcgi://127.0.0.1:9000 Install rh-php73-php-fpm (for example) with yum to run the proxy service.
On Tue, 2021-12-14 at 09:57 -0800, Kenneth Porter wrote:> On 12/14/2021 9:38 AM, TE Dukes wrote: > > Been trying to get multiple versions of PHP on a CentOS 7 machine, > > off and > > on for the past couple months. I have followed 5 or 6 different > > howtos but > > none work. They are very similar and they seems to be done on a > > fresh > > install as most do an apache install is the steps. I setup two > > virtualhosts > > one for PHP5.6 and one for PHP 7.4. When I create a file with > > phpinfo, it > > reports back 5.6.xxx on both sites. > > You should be using Software Collections to install additional > versions: > > https://www.softwarecollections.org/en/about/What about support, i.e. security updates? When I have a look at https://access.redhat.com/support/policy/updates/rhscl-rhel7 The only php SCL on that page that isn't EOL yet is php 7.3 Supported multi php installations seems difficult with that (maybe there is more behind your www.softwarecollections.org link?), although it would be possible to have the original non SCL php 5.4 in addition to the SCL php 7.3. Best Regards, Markus
On 12/14/2021 12:57 PM, Kenneth Porter wrote:> On 12/14/2021 9:38 AM, TE Dukes wrote: >> Been trying to get multiple versions of PHP on a CentOS 7 machine, off and >> on for the past couple months. I have followed 5 or 6 different howtos but >> none work. They are very similar and they seems to be done on a fresh >> install as most do an apache install is the steps. I setup two virtualhosts >> one for PHP5.6 and one for PHP 7.4. When I create a file with phpinfo, it >> reports back 5.6.xxx on both sites. > > You should be using Software Collections to install additional versions: > > https://www.softwarecollections.org/en/about/ > > Instead of running PHP within the Apache binary, use a proxy. I suggest learning how to use fcgi. Your VirtualHost could include a directive like this: > > SetHandler "proxy:fcgi://127.0.0.1:9000 > > Install rh-php73-php-fpm (for example) with yum to run the proxy service. > > > _______________________________________________ > CentOS mailing list > CentOS at centos.org > https://lists.centos.org/mailman/listinfo/centosI do not see SCL having php 7.4, only php 7.3, or did I miss it?