Centos 8 and php versions

Guys, does anyone know if Centos 8 could work with other php versions?.. It seems that I can only use 7.2. I tried going into Server Config/php options and there’s no option to choose a different version. The only PHP script execution mode I see is FPM… This is a new installation and several apps won’t work with php 7.2. Please advice. Thanks

**Centos 8
Webmin version: 1.973
Virtualmin version: 6.16
Related products version: RECOMMENDED

I’m surprised apps won’t work with 7.2.

But, if you must install other versions, I recommend you do so from a trustworthy source. SCL doesn’t seem to have anything newer than 7.2, but Remi does, and their packages tend to be pretty good.

I am not recommending you install additional PHP versions, but if you must, Remi is competent and probably won’t break much. Make sure you need it first, though. None of the apps I’ve tested have a problem with 7.2.

Thanks Joe. I’m having a hard time with these two OS. Centos and Ubuntu.

Highly advise that you move to something like CentOS Stream 8 (as CentOS 8 will be unsupported soon), however you can do something like this to get the official packages (without having to use Remi):

dnf module list php
dnf module reset php
dnf module enable php:7.4
dnf distro-sync

You can then install addtional PHP packages as required, like:

dnf install php-bcmath etc, etc.

This works with CentOS Stream 8 too.


Note that this upgrades PHP - so you’d be going from 7.2 to 7.4.

Oh, that’s good. I didn’t know you could grab stream packages without being entirely on Stream.

I wouldn’t recommend switching the OS to Stream just yet. We haven’t done any testing there. But, as a source for newer PHP versions for people that must have them, I think it’s likely a very good option (almost certainly the best option).

1 Like

This topic was automatically closed 8 days after the last reply. New replies are no longer allowed.