How to add phpMyAdmin to RHEL 7 Server?

Latest response

Hello,
I hope someone here can help me out because I called Redhat support and all I got were links to docs that don't apply to rhel 7 or are irrelevent. Searching google I issued following command to add epel: rpm -Uvh http://epel.mirror.net.in/epel/beta/7/x86_64/epel-release-7-0.2.noarch.rpm but all I get is Retrieving http://epel.mirror.net.in/epel/7/x86_64/e/epel-release-7-1.noarch.rpm

curl: (7) Failed to connect to 2401:4800:2121:c0:ff:ee:ee:2: Network is unreachable
error: skipping http://epel.mirror.net.in/epel/7/x86_64/e/epel-release-7-1.noarch.rpm - transfer failed

Can someone help me out and give me exact instructions on getting phpMyadmin installed. Thanks...

Responses

Alan,

The epel step you are using looks correct, but it appears to be a network configuration error.

Judging by the error, my guess is that you have ipv6 enabled on your RHEL7 server so it is resolving epel.mirror.net.in to an ipv6 address (AAAA record), but your server then cannot route to the epel server using ipv6.

Is your network setup/configured with ipv6?

If not I would disable ipv6 on your RHEL7 server and attempt the rpm command again and confirm that you are connecting by the ipv4 address (DNS lookup will return ipv4 of 120.88.47.14 in this case).

If you are still having issues I would confirm your network connectivity and http access out to the Internet (eg. do you require proxy access / authentication to access http from the network the RHEL7 server is in?)

I still got same error after updating to disable ipv6 and I even rebooted. Are you sure I should still be using beta url. Anyway I found another url using wget http://dl.fedoraproject.org/pub/epel/beta/7/x86_64/epel-release-7-1.noarch.rpm and see below:
[root@localhost alank]# yum repolist
Loaded plugins: product-id, subscription-manager
repo id repo name status
Webmin Webmin Distribution Neutral 188
epel/x86_64 Extra Packages for Enterpris 5,850
!rhel-7-server-extras-rpms/x86_64 Red Hat Enterprise Linux 7 S 13
!rhel-7-server-rhn-tools-rpms/7Server/x86_64 RHN Tools for Red Hat Enterp 33
!rhel-7-server-rpms/7Server/x86_64 Red Hat Enterprise Linux 7 S 4,844
rpmforge RHEL 7Server - RPMforge.net 245
repolist: 11,173
And looks like epel is registered on my system. But then I goto dependency hell:
[root@localhost alank]# yum install phpMyAdmin
Loaded plugins: product-id, subscription-manager
Resolving Dependencies
--> Running transaction check
---> Package phpMyAdmin.noarch 0:4.2.8.1-2.el7 will be installed
--> Processing Dependency: php-mcrypt >= 5.3.0 for package: phpMyAdmin-4.2.8.1-2.el7.noarch
--> Processing Dependency: php-mbstring >= 5.3.0 for package: phpMyAdmin-4.2.8.1-2.el7.noarch
--> Processing Dependency: php-tcpdf-dejavu-sans-fonts for package: phpMyAdmin-4.2.8.1-2.el7.noarch
--> Processing Dependency: php-tcpdf for package: phpMyAdmin-4.2.8.1-2.el7.noarch
--> Processing Dependency: php-php-gettext for package: phpMyAdmin-4.2.8.1-2.el7.noarch
--> Running transaction check
---> Package php-mcrypt.x86_64 0:5.4.16-2.el7 will be installed
--> Processing Dependency: libmcrypt.so.4()(64bit) for package: php-mcrypt-5.4.16-2.el7.x86_64
---> Package php-php-gettext.noarch 0:1.0.11-10.el7 will be installed
--> Processing Dependency: php-mbstring for package: php-php-gettext-1.0.11-10.el7.noarch
---> Package php-tcpdf.noarch 0:6.0.091-1.el7 will be installed
--> Processing Dependency: php-tidy for package: php-tcpdf-6.0.091-1.el7.noarch
--> Processing Dependency: php-mbstring for package: php-tcpdf-6.0.091-1.el7.noarch
--> Processing Dependency: php-bcmath for package: php-tcpdf-6.0.091-1.el7.noarch
---> Package php-tcpdf-dejavu-sans-fonts.noarch 0:6.0.091-1.el7 will be installed
--> Processing Dependency: dejavu-sans-fonts for package: php-tcpdf-dejavu-sans-fonts-6.0.091-1.el7.noarch
---> Package phpMyAdmin.noarch 0:4.2.8.1-2.el7 will be installed
--> Processing Dependency: php-mbstring >= 5.3.0 for package: phpMyAdmin-4.2.8.1-2.el7.noarch
--> Running transaction check
---> Package dejavu-sans-fonts.noarch 0:2.33-6.el7 will be installed
--> Processing Dependency: dejavu-fonts-common = 2.33-6.el7 for package: dejavu-sans-fonts-2.33-6.el7.noarch
---> Package libmcrypt.x86_64 0:2.5.8-13.el7 will be installed
---> Package php-php-gettext.noarch 0:1.0.11-10.el7 will be installed
--> Processing Dependency: php-mbstring for package: php-php-gettext-1.0.11-10.el7.noarch
---> Package php-tcpdf.noarch 0:6.0.091-1.el7 will be installed
--> Processing Dependency: php-mbstring for package: php-tcpdf-6.0.091-1.el7.noarch
--> Processing Dependency: php-bcmath for package: php-tcpdf-6.0.091-1.el7.noarch
---> Package php-tidy.x86_64 0:5.4.16-2.el7 will be installed
--> Processing Dependency: libtidy-0.99.so.0()(64bit) for package: php-tidy-5.4.16-2.el7.x86_64
---> Package phpMyAdmin.noarch 0:4.2.8.1-2.el7 will be installed
--> Processing Dependency: php-mbstring >= 5.3.0 for package: phpMyAdmin-4.2.8.1-2.el7.noarch
--> Running transaction check
---> Package dejavu-fonts-common.noarch 0:2.33-6.el7 will be installed
--> Processing Dependency: fontpackages-filesystem for package: dejavu-fonts-common-2.33-6.el7.noarch
---> Package libtidy.x86_64 0:0.99.0-31.20091203.el7 will be installed
---> Package php-php-gettext.noarch 0:1.0.11-10.el7 will be installed
--> Processing Dependency: php-mbstring for package: php-php-gettext-1.0.11-10.el7.noarch
---> Package php-tcpdf.noarch 0:6.0.091-1.el7 will be installed
--> Processing Dependency: php-mbstring for package: php-tcpdf-6.0.091-1.el7.noarch
--> Processing Dependency: php-bcmath for package: php-tcpdf-6.0.091-1.el7.noarch
---> Package phpMyAdmin.noarch 0:4.2.8.1-2.el7 will be installed
--> Processing Dependency: php-mbstring >= 5.3.0 for package: phpMyAdmin-4.2.8.1-2.el7.noarch
--> Running transaction check
---> Package fontpackages-filesystem.noarch 0:1.44-8.el7 will be installed
---> Package php-php-gettext.noarch 0:1.0.11-10.el7 will be installed
--> Processing Dependency: php-mbstring for package: php-php-gettext-1.0.11-10.el7.noarch
---> Package php-tcpdf.noarch 0:6.0.091-1.el7 will be installed
--> Processing Dependency: php-mbstring for package: php-tcpdf-6.0.091-1.el7.noarch
--> Processing Dependency: php-bcmath for package: php-tcpdf-6.0.091-1.el7.noarch
---> Package phpMyAdmin.noarch 0:4.2.8.1-2.el7 will be installed
--> Processing Dependency: php-mbstring >= 5.3.0 for package: phpMyAdmin-4.2.8.1-2.el7.noarch
--> Finished Dependency Resolution
Error: Package: php-php-gettext-1.0.11-10.el7.noarch (epel)
Requires: php-mbstring
Error: Package: php-tcpdf-6.0.091-1.el7.noarch (epel)
Requires: php-bcmath
Error: Package: phpMyAdmin-4.2.8.1-2.el7.noarch (epel)
Requires: php-mbstring >= 5.3.0
Error: Package: php-tcpdf-6.0.091-1.el7.noarch (epel)
Requires: php-mbstring
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
[root@localhost alank]#

Any help much appreciated. Also whats up with what looks like Curl using ipv6 even after I followed instructions :
Create a new file named /etc/sysctl.d/ipv6.conf and add the following options:

To disable for all interfaces

net.ipv6.conf.all.disable_ipv6 = 1

the protocol can be disabled for specific interfaces as well.

net.ipv6.conf..disable_ipv6 = 1

The new settings would then need to be reloaded with: 

sysctl -p

Thanks.

EPEL 7 is still listed as beta on the EPEL site, so beta in the URL wasn't/isn't unexpected. It appears the mirror you are using is fairly unreliable, I have just attempted to connect to it now and it is not responding, but other mirrors are working fine, it may just have been timing/luck.

To find the most recent / correct EPEL repo package for your distribution, go directly to the EPEL site:
https://fedoraproject.org/wiki/EPEL

Link for the EPEL 7 repo package is here:
http://download.fedoraproject.org/pub/epel/7/x86_64/repoview/epel-release.html

I see you have:
rhel-7-server-rpms/7Server/x86_64 Red Hat Enterprise Linux 7 S 4,844

Where is this configured from? a local ISO? RHN? Satellite server?

Both the dependencies you require are in the RHEL 7 base channel so I would expect them to be picked up correctly by yum:

php-mbstring-5.4.16-23.el7_0.x86_64.rpm
php-bcmath-5.4.16-23.el7_0.x86_64.rpm

Can you run the following:

yum clean all
yum install phpMyAdmin

If it still fails to resolve the dependency, try installing the dependencies manually before installing PhpMyAdmin (this really shouldn't be necessary)

yum install php-mbstring php-bcmath

Followup. I looked in Webmin and my ethernet interface is set to "From ipv6 discovery". Should I disable ipv6 on this interface?

If you aren't running ipv6 in your network, I would personally turn this off.

As you are able to access the repo and download the repolist etc. I would shift focus from your ipv6/networking as it is currently working, and come back and modify it later to limit the changes/variables in your yum troubleshooting.

Thanks for the input. I will try the suggestions. One question per the readout above do I have the EPEL repo on my system and you're saying the mirror isn't reliable? Should I remove it and install http://mirror.sfo12.us.leaseweb.net/epel/7/x86_64/e/epel-release-7-2.noarch.rpm? thanx...

Sing me up for this too! I tried to install phpmyadmin on my server with NO luck right now...

[pontus@GEM ~]$ sudo yum install phpmyadmin
Loaded plugins: langpacks, product-id, subscription-manager
Resolving Dependencies
--> Running transaction check
---> Package phpMyAdmin.noarch 0:4.2.9.1-1.el7 will be installed
--> Processing Dependency: php-mcrypt >= 5.3.0 for package: phpMyAdmin-4.2.9.1-1.el7.noarch
--> Processing Dependency: php-mbstring >= 5.3.0 for package: phpMyAdmin-4.2.9.1-1.el7.noarch
--> Processing Dependency: php-xmlwriter for package: phpMyAdmin-4.2.9.1-1.el7.noarch
--> Processing Dependency: php-tcpdf-dejavu-sans-fonts for package: phpMyAdmin-4.2.9.1-1.el7.noarch
--> Processing Dependency: php-tcpdf for package: phpMyAdmin-4.2.9.1-1.el7.noarch
--> Processing Dependency: php-php-gettext for package: phpMyAdmin-4.2.9.1-1.el7.noarch
--> Running transaction check
---> Package php-mcrypt.x86_64 0:5.4.16-2.el7 will be installed
--> Processing Dependency: libmcrypt.so.4()(64bit) for package: php-mcrypt-5.4.16-2.el7.x86_64
---> Package php-php-gettext.noarch 0:1.0.11-10.el7 will be installed
--> Processing Dependency: php-mbstring for package: php-php-gettext-1.0.11-10.el7.noarch
---> Package php-tcpdf.noarch 0:6.0.091-1.el7 will be installed
--> Processing Dependency: php-tidy for package: php-tcpdf-6.0.091-1.el7.noarch
--> Processing Dependency: php-mbstring for package: php-tcpdf-6.0.091-1.el7.noarch
--> Processing Dependency: php-bcmath for package: php-tcpdf-6.0.091-1.el7.noarch
---> Package php-tcpdf-dejavu-sans-fonts.noarch 0:6.0.091-1.el7 will be installed
--> Processing Dependency: dejavu-sans-fonts for package: php-tcpdf-dejavu-sans-fonts-6.0.091-1.el7.noarch
---> Package php-xml.x86_64 0:5.4.16-23.el7_0.1 will be installed
---> Package phpMyAdmin.noarch 0:4.2.9.1-1.el7 will be installed
--> Processing Dependency: php-mbstring >= 5.3.0 for package: phpMyAdmin-4.2.9.1-1.el7.noarch
--> Running transaction check
---> Package dejavu-sans-fonts.noarch 0:2.33-6.el7 will be installed
--> Processing Dependency: dejavu-fonts-common = 2.33-6.el7 for package: dejavu-sans-fonts-2.33-6.el7.noarch
---> Package libmcrypt.x86_64 0:2.5.8-13.el7 will be installed
---> Package php-php-gettext.noarch 0:1.0.11-10.el7 will be installed
--> Processing Dependency: php-mbstring for package: php-php-gettext-1.0.11-10.el7.noarch
---> Package php-tcpdf.noarch 0:6.0.091-1.el7 will be installed
--> Processing Dependency: php-mbstring for package: php-tcpdf-6.0.091-1.el7.noarch
--> Processing Dependency: php-bcmath for package: php-tcpdf-6.0.091-1.el7.noarch
---> Package php-tidy.x86_64 0:5.4.16-2.el7 will be installed
--> Processing Dependency: libtidy-0.99.so.0()(64bit) for package: php-tidy-5.4.16-2.el7.x86_64
---> Package phpMyAdmin.noarch 0:4.2.9.1-1.el7 will be installed
--> Processing Dependency: php-mbstring >= 5.3.0 for package: phpMyAdmin-4.2.9.1-1.el7.noarch
--> Running transaction check
---> Package dejavu-fonts-common.noarch 0:2.33-6.el7 will be installed
---> Package libtidy.x86_64 0:0.99.0-31.20091203.el7 will be installed
---> Package php-php-gettext.noarch 0:1.0.11-10.el7 will be installed
--> Processing Dependency: php-mbstring for package: php-php-gettext-1.0.11-10.el7.noarch
---> Package php-tcpdf.noarch 0:6.0.091-1.el7 will be installed
--> Processing Dependency: php-mbstring for package: php-tcpdf-6.0.091-1.el7.noarch
--> Processing Dependency: php-bcmath for package: php-tcpdf-6.0.091-1.el7.noarch
---> Package phpMyAdmin.noarch 0:4.2.9.1-1.el7 will be installed
--> Processing Dependency: php-mbstring >= 5.3.0 for package: phpMyAdmin-4.2.9.1-1.el7.noarch
--> Finished Dependency Resolution
Error: Package: phpMyAdmin-4.2.9.1-1.el7.noarch (epel)
Requires: php-mbstring >= 5.3.0
Error: Package: php-tcpdf-6.0.091-1.el7.noarch (epel)
Requires: php-bcmath
Error: Package: php-php-gettext-1.0.11-10.el7.noarch (epel)
Requires: php-mbstring
Error: Package: php-tcpdf-6.0.091-1.el7.noarch (epel)
Requires: php-mbstring
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
[pontus@GEM ~]$

And when trying to install php-mbstring & php-bcmath I get this:
[pontus@GEM ~]$ sudo yum install php-mbstring php-bcmath
Loaded plugins: langpacks, product-id, subscription-manager
No package php-mbstring available.
No package php-bcmath available.
Error: Nothing to do

I also did the yum clean all with no luck...

This is my repolists:
[pontus@GEM ~]$ sudo yum repolist
Loaded plugins: langpacks, product-id, subscription-manager
repo id repo name status
epel/x86_64 Extra Packages for Enterprise Linux 7 - x86_64 6,064
rhel-7-server-rpms/7Server/x86_64 Red Hat Enterprise Linux 7 Server (RPMs) 4,918
rpmforge RHEL 7Server - RPMforge.net - dag 245
repolist: 11,227

How to solve this?

Just hit this myself. After searching for those packages, found a page (http://linuxconfig.org/installation-of-missing-php-mbstring-on-rhel-7-linux) which helped me figure out that the php-mbstring and php-bcmath packages are included in the rhel-7-server-optional-rpms repository.

So the following resolved the issue for me:

subscription-manager repos --enable=rhel-7-server-optional-rpms
yum install phpmyadmin

I imagine you've probably already worked this out for your installation, but maybe this will at least help someone else out.

ıt works for me.

Works for me. Thanks Marc

For some reason adding the rhel-7-server-optional-rpms repository, did not work for me on a fresh RHEL 7.2. no phpmyadmin (nor php-mcrypt, php-bcmath, php-mbstring) packages in there (using an evaluation subscription).

What did work however is adding the epel repository (Extra Packages for Linux Enterprise, maintained by the Fedora project).

rpm -Uvh http://epel.mirror.net.in/epel/epel-release-latest-7.noarch.rpm
yum install phpMyAdmin php-mcrypt php-bcmath php-mbstring

Additionally you can list all packages in the epel repository this way :

yum --disablerepo=* --enablerepo=epel list

I found the instructions here

This page also explains how to edit the /etc/httpd/conf.d/phpMyAdmin.conf to allow access to phpmyadmin other than at localhost

And finally, phpmyadmin comes configured in a way that won't allow you to log with an empty password. so the fastest way to assign a password for the mariadb root account will be :

mysqladmin -u root password YourPasswordHere

Hope it helps :)

Hey everybody, i have the same problem, i can't install the package "phpmyadmin". The Error-Message is "no package phpmyadmin is available"

Do you have some ideas ?

Thanks

I would suggest reading the comment just above your question ;) By default phpmyadmin is NOT in the rhel-7 packages so try first adding the optional rpms :

subscription-manager repos --enable=rhel-7-server-optional-rpms
yum install phpmyadmin

And if it does nor work try the instructions I had given just above

One of the other will work

@boldair; Thanks for your help. subscription-manager, don't work but,

rpm -Uvh http://epel.mirror.net.in/epel/epel-release-latest-7.noarch.rpm yum install phpMyAdmin php-mcrypt php-bcmath php-mbstring

was very helpful. Thanks

Close

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