Red HatThis forum is for the discussion of Red Hat Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
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 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!
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)?
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...
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.
Distribution: Fedora, CentOS, RHEL and a few others
Posts: 8
Rep:
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)
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.
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).
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.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.