Skip to content
Advertisement

Install php-opcache for PHP installed via Remi’s repository

I have an environment with the following setup:

  • Centos/RHEL 8
  • PHP 7.4 installed from Remi’s repository

I have set installed php like so:

JavaScript

Now I want to install php-opcache. However dnf is reporting that there doesn’t appear to be a module php74-php-opcache.

JavaScript

I’m fairly convinced this has something to do with how repos are set up, as on my dev environment, it works.

JavaScript

Here is the output of dnf repolist on the problem environment:

JavaScript

As a sidenote, I have tried dnf install php-opcache. This is found fine. But it downloads version 7.2 and puts the opcache.so in a different location to where PHP is looking for modules and no 10-opcache.ini file. I did try manually copy these file to where this installation of PHP is looking for those files, but I got a warning

JavaScript

Advertisement

Answer

Obviously, from the pasted repolist, “remi” repository is not enabled.

For a proper configuration, follow the wizard instructions

User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement