LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices


Reply
  Search this Thread
Old 11-24-2010, 07:20 AM   #1
baysie
LQ Newbie
 
Registered: Nov 2010
Posts: 11

Rep: Reputation: 0
RHEL6 - no PHP-MCRYPT support


I had a play with the first RHEL6 beta release a while back and was very happy to see the inclusion of a wider range of PHP modules - specifically php-mcrypt. I was always disappointed that this was not available from the RHN in RHEL5.

I have spun-up a RHEL6 server now that it has been officially released, and I'm very disappointed to see that this library has been withdrawn by the RHN.

The library is fundamental to our users (phpMyAdmin is a must as far as my users are concerned - and it requires php-mcrypt) and I can't seem to find an out-of-band RPM that provides php-mcrypt for RHEL6 PHP 5.3.2 (which is what I did for RHEL5).

Is there a way around this? I really don't want to go down the route of having to uninstall the RHN supported PHP RPM's and then recompile PHP from source to include the library if it's at all avoidable.

Is there a way to install mcrypt from source and tie-it-in with the RHN installed PHP without the need to recompile? Or is there an RPM floating around somewhere for this that will work in RHEL6 x86_64?

Thanks
 
Old 11-25-2010, 10:56 AM   #2
lazlow
Senior Member
 
Registered: Jan 2006
Posts: 4,363

Rep: Reputation: 172Reputation: 172
Check the epel repo. They carry it for El5 so I would guess they will have it for El6.
 
Old 11-30-2010, 03:44 AM   #3
baysie
LQ Newbie
 
Registered: Nov 2010
Posts: 11

Original Poster
Rep: Reputation: 0
Thanks Lazlow - they indeed have a RHEL6 channel - though it's beta (at time of writing this), and unfortunately when I try to subscribe to their repository I get the following error with YUM:

Quote:
yum update
Loaded plugins: refresh-packagekit, rhnplugin
Error: Cannot retrieve repository metadata (repomd.xml) for repository: epel. Please verify its path and try again
I understand this is a common problem with their mirrors - however trying different mirrors results in the same error for me, which is a shame as, although I see no php-mcrypt, they do have a host of software which would be useful all-the-same.

But thanks for the pointer - I completely forgot about the EPEL repo's!

Cheers

Last edited by baysie; 11-30-2010 at 04:47 AM.
 
Old 12-06-2010, 06:08 AM   #4
baysie
LQ Newbie
 
Registered: Nov 2010
Posts: 11

Original Poster
Rep: Reputation: 0
OK, I'm becoming desperately disappointed with PHP in RHEL6. There is no php-devel package either, thus preventing me from installing missing libraries from source (as outlined in http://forumarchive.pro.parallels.co...ad.php?t=10028)

Other than building PHP from scratch via source files, has anyone managed to install the mcrypt library into a RHEL6 PHP server (that's running the official distribution - not the beta)?

Thanks
 
Old 12-06-2010, 09:28 AM   #5
lazlow
Senior Member
 
Registered: Jan 2006
Posts: 4,363

Rep: Reputation: 172Reputation: 172
Have you tried asking RH? That is what your subscription pays for.
 
Old 12-07-2010, 07:31 AM   #6
baysie
LQ Newbie
 
Registered: Nov 2010
Posts: 11

Original Poster
Rep: Reputation: 0
I personally haven't - but I know that others have (https://bugzilla.redhat.com/show_bug.cgi?id=621268 - this bug was closed as a "won't fix" status - see the comment from the support engineer at the bottom).

I (reluctantly) configured phpMyAdmin without cookie auth, thus bypassing the mcypt issue. But now I've come across the lack of php-mbstring support (this list of PHP modules not currently supported is border-lining on ridiculous). So I will follow your advice, Lazlow; I'll request both php-devel and php-mbstring packages with the RHN, as they were available under RHEL5 - though I won't hold my breath.

I guess until EPEL, rpmpbone.net, DAG etc. start supporting the official RHEL6 distribution - or until the RHN broadens the PHP libraries it supports (or at least provide php-devel), I will have to make do without the libraries. I'm just not sure how much longer I hold our users off from beating me - they're using PHP 5.1.6 as supplied by the RHN for RHEL5 and it's too dated now for what they want to do...
 
Old 12-07-2010, 08:40 AM   #7
baysie
LQ Newbie
 
Registered: Nov 2010
Posts: 11

Original Poster
Rep: Reputation: 0
I've figured out what's going on. Both php-devel and php-mbstring (but unfortunately not php-mcrypt) are available from the RHN - but you have to enable the "optional" repo on the RHN.

It took me a while to figure this out - as we have a local RHN satellite server, and the channel is not available on it. But the packages are clearly available as I got a 30-day trial subscription to Red Hat's RHN - and there they are. So I've contacted our local RHN admins to have a look.

Thanks for you help
 
Old 12-07-2010, 12:22 PM   #8
robertSF
LQ Newbie
 
Registered: Dec 2010
Location: The Netherlands
Distribution: Fedora, CentOS, RHEL and a few others
Posts: 8

Rep: Reputation: 1
I had the same issue (although this problem seems to be solved).

I know I could wait till epel or redhat themselves came up with the package, but since I'm installing new virtual machine's I would like to use RHEL 6 (so I can run them for a long time without outdated versions from databases and other packages). And I really needed PHP-mcrypt.

I looked at the configuration used by RHEL for the php package and altered that to something that was usable for me...
I already hear a lot of people say that it is not wise to compile stuff like that on a Production Server.

But this is how I solved it.
Downloaded php 5.3.3 and did the following:

PHP 5.3.3 on RHEL 6 (at the time of writing most php packages where not available, also not on epel)
(make sure the correct entitelments are placed in rhn, tools, Optional, Supplementary)

Code:
yum install gcc* mysql-devel mysql-devel.i686 libcurl-devel libjpeg-devel libpng-devel \
libxml2-devel openssl-devel libc-client-devel libmcrypt-devel libtool-ltdl-devel libxslt-devel \
libtidy-devel libidn-devel recode-devel libedit* aspell-devel  postgresql-devel libicu-devel \
gmp-devel freetype-devel libXpm-devel bzip2-devel pcre-devel


./configure --build=x86_64-redhat-linux-gnu --host=x86_64-redhat-linux-gnu \
 --target=x86_64-redhat-linux-gnu --program-prefix= --prefix=/usr --exec-prefix=/usr \
 --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share \
 --includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec --localstatedir=/var \
 --sharedstatedir=/var/lib --mandir=/usr/share/man --infodir=/usr/share/info \
 --cache-file=../config.cache --with-libdir=lib64 --with-config-file-path=/etc \
 --with-config-file-scan-dir=/etc/php.d --disable-debug --with-pic --disable-rpath --with-bz2 \
 --with-exec-dir --with-freetype-dir --with-png-dir --with-xpm-dir --enable-gd-native-ttf \
 --without-gdbm --with-gettext --with-gmp --with-iconv --with-jpeg-dir --with-openssl --with-zlib \
 --with-layout=GNU --enable-exif --enable-ftp --enable-magic-quotes --enable-sockets --enable-sysvsem  --enable-sysvshm \
 --enable-sysvmsg --with-kerberos --enable-ucd-snmp-hack --enable-shmop \
 --enable-calendar --without-sqlite --with-libxml-dir --enable-pcntl --with-imap --with-imap-ssl \
 --enable-mbstring --with-gd --enable-bcmath --with-mysql --with-mysqli --enable-dom  \ 
--with-pgsql --enable-wddx --enable-soap --with-xsl --enable-xmlreader --enable-xmlwriter --with-curl \ 
--enable-pdo --with-pdo-mysql --enable-json --enable-zip=shared --without-readline --with-libedit \
 --with-pspell --enable-phar --with-tidy --enable-sysvmsg=shared --enable-sysvshm=shared \
 --enable-sysvsem=shared --enable-posix=shared --enable-fileinfo
After that a make && make install.

I know a lot of hassle to get php-mcrypt..

Last edited by robertSF; 12-07-2010 at 02:50 PM. Reason: Code was a one liner
 
1 members found this post helpful.
Old 12-08-2010, 06:15 AM   #9
selachiix
LQ Newbie
 
Registered: Dec 2010
Posts: 1

Rep: Reputation: 1
I solved it in a different way.

as Baysie said, I enabled the "optional" repos on RHN and installed php-devel and mb-string.
Then I just downloaded PHP from php.net and extracted it (no install).
Browsed to the folder ext/mcrypt where PHP was extracted.
Then I executed the following commands:

# cd ext/mcrypt
# phpize
# aclocal
# ./configure
# make clean
# make
# make install

After that I created /etc/php.d/mcrypt.ini with content:
extension=mcrypt.so

So I just used the downloaded PHP for the mcrypt module.


I hope there will be a php-mcrypt package available soon.
 
1 members found this post helpful.
Old 12-08-2010, 08:46 AM   #10
lazlow
Senior Member
 
Registered: Jan 2006
Posts: 4,363

Rep: Reputation: 172Reputation: 172
You might want to pull the source rpm for the older php-mycrpt package(from beta) and have a look at the spec file. Often there are little tweaks (patches) that have been made to help make a package behave better(on that paticular distro/version).
 
Old 12-08-2010, 11:03 PM   #11
ianl678
LQ Newbie
 
Registered: Dec 2010
Posts: 1

Rep: Reputation: 1
http: //infrastructure.fedoraproject.org/5.90Server/x86_64/php-mcrypt-5.3.2-6.el6.x86_64.rpm
 
1 members found this post helpful.
Old 12-09-2010, 07:40 AM   #12
baysie
LQ Newbie
 
Registered: Nov 2010
Posts: 11

Original Poster
Rep: Reputation: 0
Thanks ianl678 - that RPM works a treat
 
Old 03-03-2011, 01:28 PM   #13
griff4472
LQ Newbie
 
Registered: Jan 2008
Location: PA - USA
Distribution: Fedora & RHEL7 (admin)
Posts: 7

Rep: Reputation: 0
php-mbstring and php-mcrypt

If you have a RHEL 6 subscription, simply add the
rhel-x86_64-server-optional-6
to your base channel (this can be done at the RHN website, and is instantly applied).
Then,
# yum install php-mcrypt php-mbstring
and you are good.

Last edited by griff4472; 03-03-2011 at 01:29 PM.
 
Old 03-26-2011, 10:34 AM   #14
manyrootsofallevil
Member
 
Registered: Dec 2010
Distribution: Red Hat, Kubuntu
Posts: 130

Rep: Reputation: 14
Quote:
Originally Posted by ianl678 View Post
http: //infrastructure.fedoraproject.org/5.90Server/x86_64/php-mcrypt-5.3.2-6.el6.x86_64.rpm
It does not look like the link http://infrastructure.fedoraproject....Server/x86_64/ contains the php-mcrypt-5.3.2-6.el6.x86_64.rpm package anymore.

Found a link here, though.

http://download.fedora.redhat.com/pu...hp-mcrypt.html

Oddly, the php-mbstring package is not there

However, it is here http://ftp.redhat.com/pub/redhat/rhe...4/os/Packages/

Last edited by manyrootsofallevil; 03-26-2011 at 11:29 AM.
 
Old 05-20-2011, 08:41 AM   #15
rhbegin
Member
 
Registered: Oct 2003
Location: Arkansas, NWA
Distribution: Fedora/CentOS/SL6
Posts: 381

Rep: Reputation: 23
This worked perfectly for phpmyadmin in RHEL6 adding the optional channel for the dependencies!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
php-mcrypt 5.1 source RPMs tmr_leon Linux - Software 0 11-27-2006 02:51 PM
RHEL3 - how do i make the php-mcrypt rpm Ratclaws Linux - Enterprise 2 07-26-2006 10:31 AM
php-mcrypt? nigeledge Linux - Software 0 10-03-2004 09:39 AM
PHP Modules (IMAP, Mcrypt, and MCAL) grahammm Linux - Software 0 08-02-2004 02:47 AM
php and mcrypt mayankjohri Linux - General 3 06-29-2002 04:20 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat

All times are GMT -5. The time now is 03:15 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration