Why is it trying to use fcgid? It shouldn’t be possible to select it, at all. Did you restore an old Virtualmin config from another server running an earlier CentOS release? Maybe your Server Templates have it set,
or something…
Anyway, fcgid is no longer a supported option in CentOS 8. So, wherever it is configured, undo it. But also tell me how you got there, because it shouldn’t be possible.
Excellent questions, Joe. and unfortunately, i do not know the answers.
you may recall (or perhaps you are suppressing it, understandably so) that last year you patiently worked with me and teaching me to avoiding third party installations, except perhaps for epel.
is there a config file i could send to you that might help determine why this might be happening? or if you want, we could do some sort of screen-share at your convenience, whatever you think.
By installing php-fpm.x86_64 normal PHP becomes PHP-FPM. That’s what you want and it’s how PHP is shipped with CentOS 8. The output above looks normal except for one thing…
CentOS 8 continues to ship with PHP 7.2 as the default even though AppStream can now provide 7.3 and 7.4. It appears the default hasn’t changed and that you have two parallel installations of 7.2 from two different repos.
If any of these three 7.x versions work for you as the defaullt global PHP installation, there’s no reason to be using Remi’s repo. Currently the only reason for Remi is to replace global PHP with version 8 or for multiple installations that are different from global.
With dnf you can switch the global default and upgrade 7.2 as high as AppStream will go. So with the following you’d be replacing 7.2 with 7.4:
To check at the command line use php -v for the global installation and /usr/bin/php72 -v for the extra from Remi. The full path to the binary symlink is necessary for Remi add-on installations, but not for the global default installation.
The global installation uses /etc/php.ini and the extra 7.2 installation from Remi uses /etc/opt/remi/php72/php.ini.
Get rid of extra Remi installations at your leisure but always keep the global installation.
You could start with dnf remove php72, observe what happens, then use dnf info php72 to see if there are leftovers. PHP’s cli, common and devel will probably be removed along with core packages.
Usually with a Remi PHP installation some dependencies and most PHP extensions install separately from main packages and need to be removed the same way. It’s easier to stack them in a single command.
Well, instead of two 7.2 installations it looks like you now have a pair of 7.4 installations from different repos. And I’m wondering if you’ve possibly got three total if 7.2 from Remi wasn’t removed when 7.4 from Remi was added. Do you see directories for both php72 and php74 when you type ls /etc/opt/remi?
Output from these commands will say for sure if there are two Remi installations:
php72 -v
systemctl status php72-php-fpm
php74 -v
systemctl status php74-php-fpm
If the shorter php?? -v commands aren’t working try full paths:
/usr/bin/php72 -v
/usr/bin/php74 -v
For the global installation it works this way regardless of the version installed:
php -v
systemctl status php-fpm
I think installing 7.4 from AppStream as the global default was the right move. But the 7.4 packages from Remi need to go so that packages come only from CentOS. I’m not clear about what happened but here’s what I think you should do to get on track:
Remove all traces of Remi PHP installations including modules that were added.
Disable all Remi repos when you’re satisfied everything installed from Remi was removed.
Focus on the global PHP installation using only CentOS repos, mainly AppStream.
Run dnf update php\* again to make sure dependencies are resolved by CentOS repos.
To disable Remi repos open every /etc/yum.repos.d/remi* file with an editor and replace enabled=1 with enabled=0. Then run dnf clean all.
Once global PHP is tip-top and working for you, and you decide at some point you need an older 7.x version or want to try PHP 8, you can always re-enable Remi by toggling those 0s to 1s.
The above packages look like they’re from Remi so might as well remove them.
With third-party repos like Remi and SCL installed it’s important to differentiate how they name their PHP packages. If you accidentally remove something from CentOS AppStream you can always add it back but make sure Remi is uninstalled first.
Depending on the system which creates the php builts, it might very well be possible to have different php versions on the same time being finished.
And since you did install them and didn’t remove them, it is pretty much normal that there are multiple versions. If you wanted to remove one of them, then it looks like you just forgot one of them.
This looks just right and I see no discrepancies. By resetting the PHP module to 7.4 earlier with dnf, package management now assumes 7.4 for anything PHP.
Now, if you later decided to add different PHP versions from Remi (any but 7.4), study the configuration wizard at his site. Particularly how yum/dnf usage differs between “single” and “multiple” installations. Your only concern at this point would be how multiples are installed. Your single install is the one you just did with AppStream. I recommend sitting on this one install for simplicity and less maintenance, and especially if 7.4 is all you’ll need.