php7 on rhel7.4

Latest response

Question: How do I get php7x?
"yum search php7" does not show up after the following:
I reinstalled rhel-server-7.4-x86_64-dvd.iso on a paid subscription.
And authenticated with redhat .
We have an application we run using php and would like to install php7x

I am currently testing the install with rhel-7.4 on a VM. (VMWare)

I am following these instructions:
https://developers.redhat.com/products/softwarecollections/hello-world/#fndtn-php
and have enabled the following with the following command

subscription-manager repos --enable rhel-server-rhscl-7-beta-rpms

Repository 'rhel-server-rhscl-7-beta-rpms' is enabled for this system.

yum search php7

does not show up

subscription-manager repos --list | egrep rhscl

Repo ID: rhel-server-rhscl-7-beta-source-rpms
Repo ID: rhel-server-rhscl-7-beta-debug-rpms
Repo ID: rhel-server-rhscl-7-beta-rpms

No luck

notes:
subscription-manager attach --auto

All installed products are covered by valid entitlements. No need to update subscriptions at this time.

Installed Product Current Status:
Product Name: Red Hat Enterprise Linux Server
Status: Subscribed

Responses

Hi Craig,

Execute these commands to enable the RHSCL repo which contains the packages :

sudo subscription-manager repos --enable rhel-7-server-extras-rpms
sudo subscription-manager repos --enable rhel-7-server-optional-rpms
sudo subscription-manager repos --enable rhel-server-rhscl-7-rpms

Then update the software sources : sudo yum update and install the packages. :)

Regards,
Christian

Christian, I went online and found the php71. https://access.redhat.com/downloads/content/205/ver=1/rhel---7/1/x86_64/packages I tried to search for php71 and got the following:

cwc@redhat ~]$ yum search php71
Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-manager
Repo rhel-7-server-extras-rpms forced skip_if_unavailable=True due to: /etc/pki/entitlement/4687930966587225300-key.pem
Repo rhel-7-server-rpms forced skip_if_unavailable=True due to: /etc/pki/entitlement/4687930966587225300-key.pem
Repo rhel-7-server-extras-beta-rpms forced skip_if_unavailable=True due to: /etc/pki/entitlement/4687930966587225300-key.pem
Repo rhel-7-server-optional-rpms forced skip_if_unavailable=True due to: /etc/pki/entitlement/4687930966587225300-key.pem
Repo rhel-server-rhscl-7-beta-source-rpms forced skip_if_unavailable=True due to: /etc/pki/entitlement/8143605796696588455-key.pem
Repo rhel-server-rhscl-7-beta-debug-rpms forced skip_if_unavailable=True due to: /etc/pki/entitlement/8143605796696588455-key.pem
Repo rhel-server-rhscl-7-beta-rpms forced skip_if_unavailable=True due to: /etc/pki/entitlement/8143605796696588455-key.pem
Warning: No matches found for: php71
No matches found
[cwc@redhat ~]$ 



Hi Craig,

There seems to be something wrong with the attachment of your subscription, so refresh everything :

sudo subscription-manager remove --all
sudo subscription-manager unregister
sudo subscription-manager clean

sudo subscription-manager register
sudo subscription-manager refresh
sudo subscription-manager attach --auto

sudo subscription-manager repos --enable rhel-7-server-extras-rpms
sudo subscription-manager repos --enable rhel-7-server-optional-rpms
sudo subscription-manager repos --enable rhel-server-rhscl-7-rpms

sudo yum clean all
sudo rm -rf /var/cache/yum
sudo yum update

Regards,
Christian

All, I know this is an old thread but I wanted to pass it on to the community. So, I have through my University the RHEL Academic version with Self-Support, the RHEL Academic version does not have access to all of the repos a standard version does. Please see below from the RedHat support;

"As per your queries, I would like to inform you that, - None of your Self Support subscriptions provides access to RHSCL Repositories for GA Release version of OS. "

I was able to get the php7x by following the recommended configurations provided to me by support.

# subscription-manager attach --pool=8a85f98c635f699f016374b1eabb0c06
# subscription-manager repos --enable=rhel-server-rhscl-7-rpms 
# yum clean all
# yum install rh-php70
# scl enable rh-php70 bash 

Hi Manuel,

Thanks for sharing this information. Although, it is a known fact that the accessibility of repositories depends on the individual subscription, which is different for every Red Hat account/user of course. :)

Regards,
Christian

Thanks for the post:

I executed the following:
sudo subscription-manager repos --enable rhel-7-server-extras-rpms
sudo subscription-manager repos --enable rhel-7-server-optional-rpms
sudo subscription-manager repos --enable rhel-server-rhscl-7-rpms

NO LUCK ?

[cwc@localhost http]$ sudo yum update
Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-manager
No packages marked for update
[cwc@localhost http]$ sudo yum search php
Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-manager
============================================================================= N/S matched: php ==============================================================================
graphviz-php.x86_64 : PHP extension for graphviz
php.x86_64 : PHP scripting language for creating dynamic web sites
php-bcmath.x86_64 : A module for PHP applications for using the bcmath library
php-cli.x86_64 : Command-line interface for PHP
php-common.x86_64 : Common files for PHP
php-dba.x86_64 : A database abstraction layer module for PHP applications
php-devel.x86_64 : Files needed for building PHP extensions
php-embedded.x86_64 : PHP library for embedding in applications
php-enchant.x86_64 : Enchant spelling extension for PHP applications
php-fpm.x86_64 : PHP FastCGI Process Manager
php-gd.x86_64 : A module for PHP applications for using the gd graphics library
php-intl.x86_64 : Internationalization extension for PHP applications
php-ldap.x86_64 : A module for PHP applications that use LDAP
php-mbstring.x86_64 : A module for PHP applications which need multi-byte string handling
php-mysql.x86_64 : A module for PHP applications that use MySQL databases
php-mysqlnd.x86_64 : A module for PHP applications that use MySQL databases
php-odbc.x86_64 : A module for PHP applications that use ODBC databases
php-pdo.x86_64 : A database access abstraction module for PHP applications
php-pear.noarch : PHP Extension and Application Repository framework
php-pgsql.x86_64 : A PostgreSQL database module for PHP
php-process.x86_64 : Modules for PHP script using system process interfaces
php-pspell.x86_64 : A module for PHP applications for using pspell interfaces
php-recode.x86_64 : A module for PHP applications for using the recode library
php-snmp.x86_64 : A module for PHP applications that query SNMP-managed devices
php-soap.x86_64 : A module for PHP applications that use the SOAP protocol
php-xml.x86_64 : A module for PHP applications which use XML
php-xmlrpc.x86_64 : A module for PHP applications which use the XML-RPC protocol
rrdtool-php.x86_64 : PHP RRDtool bindings
uuid-php.x86_64 : PHP support for Universally Unique Identifier library
php-pecl-memcache.x86_64 : Extension to work with the Memcached caching daemon

  Name and summary matches only, use "search all" for everything.
[cwc@localhost http]$ sudo yum search php7
Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-manager
Warning: No matches found for: php7
No matches found

Hi Craig,

The package name is rh-php70 ... so : sudo yum search rh-php70 and sudo yum install rh-php70
Or in case you want version 7.1 it'd be : sudo yum search rh-php71 and sudo yum install rh-php71

Cheers :)
Christian

Thanks again, No luck. I am running this on a test VM using a 30 day trial but the superscription is authenticated.

# yum search rh-php70
Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-manager
Warning: No matches found for: rh-php70
No matches found
[root@localhost http]# yum search rh-php71
Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-manager
Warning: No matches found for: rh-php71
No matches found
[root@localhost http]# 

I thought I needed the following:
[root@localhost http]# sudo subscription-manager repos --list | grep rhscl
Repo ID:   rhel-server-rhscl-7-beta-source-rpms
Repo URL:  https://cdn.redhat.com/content/beta/rhel/server/7/$basearch/rhscl/1/source/SRPMS
Repo ID:   rhel-server-rhscl-7-beta-debug-rpms
Repo URL:  https://cdn.redhat.com/content/beta/rhel/server/7/$basearch/rhscl/1/debug
Repo ID:   rhel-server-rhscl-7-beta-rpms
Repo URL:  https://cdn.redhat.com/content/beta/rhel/server/7/$basearch/rhscl/1/os
[root@localhost http]# 

Hi Craig,

Please check whether the repositories are enabled : sudo subscription-manager repos --list-enabled
As you can see here in the Red Hat Package Browser, the rh-php70 and rh-php71 packages are available. :)

Regards,
Christian

woops a error here:

[root@localhost http]# subscription-manager repos --enable rhel-server-rhscl-7-rpms
Error: 'rhel-server-rhscl-7-rpms' does not match a valid repository ID. Use "subscription-manager repos --list" to see valid repositories.
[root@localhost http]# 
I  have this enabled:
rhel-server-rhscl-7-beta-rpms

<pre><code>Here's what I've enabled:
[root@localhost http]# subscription-manager repos --list-enabled +----------------------------------------------------------+ Available Repositories in /etc/yum.repos.d/redhat.repo +----------------------------------------------------------+ Repo ID: rhel-7-server-extras-rpms Repo Name: Red Hat Enterprise Linux 7 Server - Extras (RPMs) Repo URL: https://cdn.redhat.com/content/dist/rhel/server/7/7Server/$basearch/extras/os Enabled: 1 Repo ID: rhel-server-rhscl-7-beta-source-rpms Repo Name: Red Hat Software Collections Beta Source RPMs for Red Hat Enterprise Linux 7 Server Repo URL: https://cdn.redhat.com/content/beta/rhel/server/7/$basearch/rhscl/1/source/SRPMS Enabled: 1 Repo ID: rhel-server-rhscl-7-beta-debug-rpms Repo Name: Red Hat Software Collections Beta Debug RPMs for Red Hat Enterprise Linux 7 Server Repo URL: https://cdn.redhat.com/content/beta/rhel/server/7/$basearch/rhscl/1/debug Enabled: 1 Repo ID: rhel-server-rhscl-7-beta-rpms Repo Name: Red Hat Software Collections Beta RPMs for Red Hat Enterprise Linux 7 Server Repo URL: https://cdn.redhat.com/content/beta/rhel/server/7/$basearch/rhscl/1/os Enabled: 1 Repo ID: rhel-7-server-rpms Repo Name: Red Hat Enterprise Linux 7 Server (RPMs) Repo URL: https://cdn.redhat.com/content/dist/rhel/server/7/$releasever/$basearch/os Enabled: 1 Repo ID: rhel-7-server-extras-beta-rpms Repo Name: Red Hat Enterprise Linux 7 Server - Extras Beta (RPMs) Repo URL: https://cdn.redhat.com/content/beta/rhel/x86_64/7/$basearch/extras/os Enabled: 1 Repo ID: rhel-7-server-optional-rpms Repo Name: Red Hat Enterprise Linux 7 Server - Optional (RPMs) Repo URL: https://cdn.redhat.com/content/dist/rhel/server/7/$releasever/$basearch/optional/os Enabled: 1 [root@localhost http]#

Hi Craig,

I don't know why you can use the beta channel but not the stable one ... you should contact the Customer Support. :)

Regards,
Christian

Thank you. At least I know I am on the correct path. I appreciate your help! Craig

started with redhat 7 in 2001

You're welcome Craig,

But what does "Craig started with redhat 7 in 2001" mean ? :)

Regards,
Christian

It is Red Hat Linux v7. See this wikipedia article for details. I believe my first RHL was v5. :-)

Just a note. I started with Linux in 2001 using Redhat 7 . It's come a long way since then. I used EL4 and now RHEL7 Things changed since 2001

Thanks for the information Akemi ! :)
Thank you for clarification Craig ! :)

Regards,
Christian

Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.