0

I am a newbie in Linux. While trying install PHP-7.4 on CentOS 8 by instruction in https://rpms.remirepo.net/wizard/, I get error Unable to resolve argument php:remi-7.4 at command dnf module install php:remi-7.4

On CentOS PHP-7.3.22 is already installed. Please help.

Unable to resolve argument php:remi-7.4
No match for package php-cli
Unable to resolve argument php:remi-7.4
No match for package php-common
Unable to resolve argument php:remi-7.4
No match for package php-fpm
Unable to resolve argument php:remi-7.4
No match for package php-mbstring
Unable to resolve argument php:remi-7.4
No match for package php-xml
Error: Problems in request:
broken groups or modules: php:remi-7.4, php:remi-7.4, php:remi-7.4, php:remi-7.4, php:remi-7.4
Quang Chung
  • 1
  • 1
  • 1

1 Answers1

0

I ran into a similar problem with a fresh install of CentOS 8. First, I had to add the EPEL 8 repo

sudo dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm -y
sudo dnf install https://rpms.remirepo.net/enterprise/remi-release-8.rpm -y

Then disable all options for all php versions, then enable the repo for remi-7.4, specifically.

sudo dnf module reset php -y
sudo dnf module install php:remi-7.4 -y
sudo yum install yum-utils -y

After that, you can do

sudo yum install php

and it will install php from the only php repo avaialble (remi-7.4).

For reference: https://blog.remirepo.net/post/2019/12/03/Install-PHP-7.4-on-CentOS-RHEL-or-Fedora

CIA
  • 1,604
  • 2
  • 13
  • 32
  • PHP 7.4 is in the CentOS 8 repos so one can just `yum install php` without having to use Remi. – Nasir Riley Nov 02 '21 at 06:12
  • Indeed, remi is only required for older versions (7.2, 7.3) or newer versions (8.0, 8.1) or if for additional extensions (sodium, oci8, imagick, redis, memcache...) – Remi Collet Nov 02 '21 at 06:47
  • I don’t know what to tell you guys. If it was working the way you guys say it should, then I wouldn’t have needed to do all the steps above. But, it didn’t work the way you said it does, so I did follow those instructions to get PHP7.4 installed on my system. – CIA Nov 03 '21 at 13:37