Topic: No package php available

Hello,

I am new to CentOS and the Remi repository, but i'm very known with Debian.
I want to install php 5.6 from the Remi repository, but the packages cannot be find by yum.

EPEL and Remi are installed on the server.
# rpm -Uvh remi-release-7.rpm epel-release-latest-7.noarch.rpm

[remi] and [remi-php56] are enabled with enabled=1

# yum repolist

Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
 * base: centos.mirror.transip.nl
 * centosplus: centos.mirror.transip.nl
 * epel: mirror.nl.leaseweb.net
 * extras: centos.mirror.transip.nl
 * remi: remi.mirrors.cu.be
 * remi-php56: remi.mirrors.cu.be
 * remi-safe: remi.mirrors.cu.be
 * updates: centos.mirror.transip.nl
 * webtatic: uk.repo.webtatic.com
repo id                                                                                                      repo name                                                                                                                                                  status
base/7/x86_64                                                                                                CentOS-7 - Base                                                                                                                                            8871+136
centosplus/7/x86_64                                                                                          CentOS-7 - Plus                                                                                                                                                  53
epel/x86_64                                                                                                  Extra Packages for Enterprise Linux 7 - x86_64                                                                                                             8895+769
extras/7/x86_64                                                                                              CentOS-7 - Extras                                                                                                                                               226
remi                                                                                                         Remi's RPM repository for Enterprise Linux 7 - x86_64                                                                                                      172+2576
remi-php56                                                                                                   Remi's PHP 5.6 RPM repository for Enterprise Linux 7 - x86_64                                                                                                 7+340
remi-php56-debuginfo/x86_64                                                                                  Remi's PHP 5.6 RPM repository for Enterprise Linux 7 - x86_64 - debuginfo                                                                                     0+236
remi-safe                                                                                                    Safe Remi's RPM repository for Enterprise Linux 7 - x86_64                                                                                                   36+700
updates/7/x86_64                                                                                             CentOS-7 - Updates                                                                                                                                            934+8
webtatic/x86_64                                                                                              Webtatic Repository EL7 - x86_64                                                                                                                              6+267
repolist: 19200

Everything seems ok, but I can't install any package from the repository.

# yum install php

Failed to set locale, defaulting to C
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
 * base: centos.mirror.transip.nl
 * centosplus: centos.mirror.transip.nl
 * epel: mirror.nl.leaseweb.net
 * extras: centos.mirror.transip.nl
 * remi: remi.mirrors.cu.be
 * remi-php56: remi.mirrors.cu.be
 * remi-safe: remi.mirrors.cu.be
 * updates: centos.mirror.transip.nl
 * webtatic: uk.repo.webtatic.com
No package php available.

I have also tried yum install php56 and php-56, but that fails with the same message.

Is there something I can do to fix this problem?

Re: No package php available

1/ remove the webtatic repo, which will raise issue when remi-php56 is enable.

2/ looks like a cpanel server ?

Try to find "exclude" in yum configuration

grep exclude /etc/yum.conf /etc/yum.repos.d/*repo
Laptop:  Fedora 38 + rpmfusion + remi (SCL only)
x86_64 builder: Fedora 39 + rpmfusion + remi-test
aarch64 builder: RHEL 9 with EPEL
Hosting Server: CentOS 8 Stream with EPEL, rpmfusion, remi

Re: No package php available

Thank you.

Some web related packages are excluded in yum.conf.
exclude=apache* httpd* mod_* mysql* MySQL* mariadb* da_* *ftp* exim* sendmail* php* bind-chroot*

It is a DirectAdmin server. Can that be the reason this packages are excluded? To avoid conflicts with the Apache related packages for DirectAdmin?

Re: No package php available

DirectAdmin provide its own PHP stack, and exclude any other sources.

So you can't update, or you may break everything.

Laptop:  Fedora 38 + rpmfusion + remi (SCL only)
x86_64 builder: Fedora 39 + rpmfusion + remi-test
aarch64 builder: RHEL 9 with EPEL
Hosting Server: CentOS 8 Stream with EPEL, rpmfusion, remi

Re: No package php available

Perhaps you can install the SCL (php56-php* package) as this one will be installed beside the default system version used by DirectAdmin.

But you will have to manuall enable it per project / vhost using the SetHandler to fastcgi proxy

NO Warranty

Use a real CentOS and learn to administrate your server without any panel wink

Laptop:  Fedora 38 + rpmfusion + remi (SCL only)
x86_64 builder: Fedora 39 + rpmfusion + remi-test
aarch64 builder: RHEL 9 with EPEL
Hosting Server: CentOS 8 Stream with EPEL, rpmfusion, remi

Re: No package php available

Not all my colleagues are familiar with managing a Linux server. That is why we have chosen a control panel.
I will have to talk to him about this. smile