Score:0

Need to add older version of IUS repo in order to install specific PHP 7.2 packages

pl flag

The Issue:

Without unnecessary detail, I have two servers that are nearly identical. However one has its yum repos configured such that php 7.2 packages imagick and sodium are available for install, whereas the other doesn't.

Same exact kernel version:

CentOS Linux release 7.5.1804 (Core)

Similar PHP versions:

Server A:

PHP 7.2.18 (cli)

Server B:

PHP 7.2.20 (cli)

Server A:

$ sudo yum search sodium imagick
...
php72u-sodium.x86_64 : Wrapper for the Sodium cryptographic library
php72u-pecl-imagick.x86_64 : Provides a wrapper to the ImageMagick library
...

Server B:

$ sudo yum search sodium imagick
[only versions for php 7.3 and 7.4 shown]

I believe this is due to the configuration of the yum repos, in particular the ius repo:

Server A:

$ sudo yum repolist
Loaded plugins: fastestmirror, replace
Loading mirror speeds from cached hostfile
 * base: d36uatko69830t.cloudfront.net
 * epel: iad.mirror.rackspace.com
 * extras: d36uatko69830t.cloudfront.net
 * ius: ius.mirror.constant.com <================ THIS ONE
 * updates: d36uatko69830t.cloudfront.net
...

Server B:

$ sudo yum repolist
Loaded plugins: fastestmirror, replace
Loading mirror speeds from cached hostfile
 * base: d36uatko69830t.cloudfront.net
 * epel: dl.fedoraproject.org
 * extras: d36uatko69830t.cloudfront.net
 * updates: d36uatko69830t.cloudfront.net
...

So in short I need to figure out how to configure server B to have that same IUS repo (at the same version so it has PHP 7.2 packages available!)

Things I've Tried

  • Installing the IUS repo from scratch following their instructions.
  • Copying the full /etc/yum.repos.d/ directory over from Server A to B, then running yum clean all
  • Installing these modules manually with pecl

But none of these attempts worked. The results:

  • The newest IUS which still didn't have these packages available.
  • Didn't seem to make a difference (or maybe broke the IUS repo, I can't recall now).
  • Pecl similarly didn't have the PHP 7.2 versions of these modules available.
Score:0
cn flag

Upgrade to a newer PHP, as of June 2021 7.3 or 7.4. And subscribe to IUS's notices and testing repo so version updates are not a surprise in the future.

PHP 7.2 is no longer available from IUS as upstream support ended. Indeed, the repo name stands for Inline with Upstream Stable. Their scheme of version number in the package name enables choice of version (php74-pecl-imagick). See also IUS FAQ.

CentOS and related repos do not keep older packages around, they are archived. Consider maintaining a private mirror with copies of packages at specific versions. This has limits, older packages will not have fixes, including security updates.

Also upgrade the rest of your packages, as CentOS 7.5 support has ended. If you want minor releases for an extended period of time, consider RHEL with extended update support.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.