LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 03-06-2012, 12:56 PM   #1
XRayden
LQ Newbie
 
Registered: Sep 2011
Location: Quebec, Qc, Canada
Distribution: CentOS
Posts: 10

Rep: Reputation: Disabled
mcrypt php 5.2.17


I've try installin php-mcrypt the... hum easy way:
yum install php-mcrypt

but it is not on any repo

so i tried with atomic repo, witch... does not work either

then i've tried installing it with rpms from atomics

with php-common (dependancy)

seams to have install... but after httpd restart, it's still not in phpinfo, and cause error searching for "php_mcrypt.dll"

i've search the entire server for the dll... not found...

I do not know where i've gone wrong....
 
Old 03-06-2012, 04:19 PM   #2
bathory
Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 10,881

Rep: Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322
Hi,
Quote:
seams to have install... but after httpd restart, it's still not in phpinfo, and cause error searching for "php_mcrypt.dll"

i've search the entire server for the dll... not found...
A .dll file is a windows dynamic library, so I guess you've done something wrong...
After a search in rpm.pbone.net, there exist php-mcrypt-5.2.17 packages for RHEL5. You can download the one that fits your distro/arch and install it using rpm

Regards
 
Old 03-06-2012, 05:17 PM   #3
anomie
Senior Member
 
Registered: Nov 2004
Location: Texas
Distribution: RHEL, Scientific Linux, Debian, Fedora, Lubuntu, FreeBSD
Posts: 3,930
Blog Entries: 5

Rep: Reputation: Disabled
If you're using RHEL (or RHEL-"clone"), it's also available on EPEL.

http://fedoraproject.org/wiki/EPEL
 
Old 03-06-2012, 05:21 PM   #4
lithos
Senior Member
 
Registered: Jan 2010
Location: SI : 45.9531, 15.4894
Distribution: CentOS, OpenNA/Trustix, testing desktop openSuse 12.1 /Cinnamon/KDE4.8
Posts: 1,144

Rep: Reputation: 217Reputation: 217Reputation: 217
Hi XRayden

I would recommend you to use Webtatic

go to near bottom of the page where the section "PHP 5.2.17" explains how to install Version 5.2.17 (not 5.3)

I did, it's working flawless.

good luck
 
Old 03-12-2012, 08:02 AM   #5
XRayden
LQ Newbie
 
Registered: Sep 2011
Location: Quebec, Qc, Canada
Distribution: CentOS
Posts: 10

Original Poster
Rep: Reputation: Disabled
Thanks to all of you!

first i've found out that there was an
exclude=php*
in my /etc/yum.conf

so it was normal to have this problem

second, the php.ini is setup elsewhere on this server (suphp) than /etc/php.ini BUT /etc/php.ini exist, just not in use

now... i've followed Webtatic install

i've tried this command to see if it's ok:

root@*domain* [~]# rpm -qa | grep php
php-mcrypt-5.2.17-1.el5.art
php-common-5.2.17-1.el5.art
php-mcrypt-5.2.17-1.el5.art

and modified the TRUE php.ini (the one given by phpinfo()) to ad the extension
extension=/usr/lib64/php/modules/mcrypt.so

restarted apache, BUT mcrypt is still not loaded in the phpinfo()

is there any other config to "displace" to the real php.ini to make it work?
 
Old 03-12-2012, 09:01 AM   #6
bathory
Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 10,881

Rep: Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322
Quote:
root@*domain* [~]# rpm -qa | grep php
php-mcrypt-5.2.17-1.el5.art
php-common-5.2.17-1.el5.art
php-mcrypt-5.2.17-1.el5.art
How come 2 occurrences of php-mcrypt? And you miss the main php-5.2.17-1 package


Quote:
and modified the TRUE php.ini (the one given by phpinfo()) to ad the extension
extension=/usr/lib64/php/modules/mcrypt.so
It should be taken care by the package manager. There should be created a /etc/php.d/mcrypt.ini containing the correct extension syntax for mcrypt

What gives:
Code:
php -i|grep -i mcrypt

Last edited by bathory; 03-12-2012 at 09:02 AM.
 
Old 03-12-2012, 09:35 AM   #7
XRayden
LQ Newbie
 
Registered: Sep 2011
Location: Quebec, Qc, Canada
Distribution: CentOS
Posts: 10

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by bathory View Post
How come 2 occurrences of php-mcrypt? And you miss the main php-5.2.17-1 package
php is not at all in the rpm list, seams to have been compile with apache on WHM/cPanel install
as for the 2 mcrypt, on yum install of php-mcrypt, i386 and x64 are installed



Quote:
Originally Posted by bathory View Post
It should be taken care by the package manager. There should be created a /etc/php.d/mcrypt.ini containing the correct extension syntax for mcrypt
there is a mcrypt.ini, with this code:
; Enable mcrypt extension module
extension=mcrypt.so

but does not seams to have been loaded

What gives:
Quote:
Originally Posted by bathory View Post
Code:
php -i|grep -i mcrypt
Nothing...
 
Old 03-12-2012, 01:37 PM   #8
bathory
Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 10,881

Rep: Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322Reputation: 1322
Quote:
php is not at all in the rpm list, seams to have been compile with apache on WHM/cPanel install
Are you sure php was compiled from source? In this case you cannot add a php extension using a rpm package, while php was compiled from source
Either install everything related to php using yum, or uninstall those php packages and keep reading.

Quote:
as for the 2 mcrypt, on yum install of php-mcrypt, i386 and x64 are installed
The package management tool (yum) does not install packages for both architectures. If it was, there should be noted in the package name, e.g. php-mcrypt-5.2.17-1.el5-x86_64.art


Quote:
there is a mcrypt.ini, with this code:
; Enable mcrypt extension module
extension=mcrypt.so

but does not seams to have been loaded
That mcrypt.ini was created by yum, but it's not loaded because your php does not know about it. Besides as already mentioned above, you cannot load a precompiled extension into a php compiled from source.

What you can do in case php was compiled from source, is to uninstall those php packages and then go into the php sources directory (e.g. /php-5.2.17). In that directory, as root, run the following
Code:
cd ext/mcrypt
phpize
./configure
make
make install
Check php.ini and make sure the "extension = mcrypt.so" in uncommented

Regards
 
  


Reply

Tags
php5 apache


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Depsolving problems php-mcrypt WzJazz Linux - Enterprise 6 07-04-2011 07:35 PM
[SOLVED] RHEL6 - no PHP-MCRYPT support baysie Red Hat 19 06-09-2011 04:06 PM
php-mcrypt 5.1 source RPMs tmr_leon Linux - Software 0 11-27-2006 02:51 PM
php-mcrypt? nigeledge Linux - Software 0 10-03-2004 09:39 AM
php and mcrypt mayankjohri Linux - General 3 06-29-2002 04:20 AM


All times are GMT -5. The time now is 01:38 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration