Solved

mcrypt

Posted on 2011-09-14
11
602 Views
Last Modified: 2012-05-12
Hi i try to install mcrypt on centos. I intall it using yum and it said it installed. I try to restart apache and nothing happens. It just do not work in php. How i can fix it.
0
Comment
Question by:umaxim
  • 7
  • 4
11 Comments
 
LVL 29

Expert Comment

by:Randy Downs
ID: 36536566
0
 
LVL 29

Expert Comment

by:Randy Downs
ID: 36536577
Update PHP packages
Before updating your PHP packages you'll want to get a list of what you currently have installed. To get a list of current PHP packages run the following:

 # rpm -qa |grep php
Now you can use yum to update the PHP packages on your system:

 # yum update
You should be shown a list of packages that are going to be updated. Compare it to the list of PHP packages on your system. Note any packages that are not in the list. You'll need to remove these packages or find updates for them because they won't work after you update to PHP 5.2.x. If that is acceptable type "y" to continue and let yum update the packages.
Once yum has completed restart Apache:

 # service httpd restart
To verify the update is working create a simple testing.php in your www directory with the following source code:

<?php
  phpinfo();
?>
and open it in a web browser. The new PHP version should be reflected at the top of the page.
0
 
LVL 1

Author Comment

by:umaxim
ID: 36536605
still do not see anything in my phpinfo()
http://cl.iwebpixels.com/test.php
0
 
LVL 29

Expert Comment

by:Randy Downs
ID: 36536703
extension commented out in php.ini?

0
 
LVL 29

Expert Comment

by:Randy Downs
ID: 36536718
0
Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

 
LVL 1

Author Comment

by:umaxim
ID: 36536783
i did not found it in php.ini
0
 
LVL 29

Expert Comment

by:Randy Downs
ID: 36536829
OK looks like it's not used

http://www.centos.org/modules/newbb/viewtopic.php?topic_id=13618

The php-mcrypt configuration file is /etc/php.d/mcrypt.ini, it's loaded automatically. No changes to /etc/php.ini are needed.
0
 
LVL 1

Author Comment

by:umaxim
ID: 36536845
yes this is my case
0
 
LVL 29

Expert Comment

by:Randy Downs
ID: 36536888
Did you try this? Note that the versions of php are probably different.

Updating/Installing mcrypt
If you have php-mcrypt for PHP 5.1.x installed you'll want to remove it:
Note: Your version number maybe different. Alter below command accordingly.

 rpm -e php-mcrypt-5.1.6-15.el5.centos.1
Download php-mcrypt for PHP 5.2.x and install it. You can find a 32-bit php-mcrypt package here FedoraJunkies.
Note: You'll notice the "--nodeps" flag in the example. When you try to install php-mcrypt without it you get an error that php-common-5.2.6-2.el5s2 is missing even though it is installed.

 wget -c http://sourcemirrors.org/scotth/centos/5/php/php-mcrypt-5.2.6-2.i386.rpm
 rpm -i --nodeps php-mcrypt-5.2.6-2.i386.rpm
Restart Apache and you should now see mcrypt information on your testing.php page.
0
 
LVL 1

Author Comment

by:umaxim
ID: 36537053
it said connection refusend when i try to download file
0
 
LVL 29

Accepted Solution

by:
Randy Downs earned 500 total points
ID: 36537314
That site no longer works. If you have 64 bit machine these should be OK

http://www.atoomnet.net/centos_updated_php.php

wget 'http://www.atoomnet.net/./php/php-5.2.17/php-mcrypt-5.2.17-1.x86_64.rpm'
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

Using 'screen' for session sharing, The Simple Edition Step 1: user starts session with command: screen Step 2: other user (logged in with same user account) connects with command: screen -x Done. Both users are connected to the same CLI sessio…
Introduction We as admins face situation where we need to redirect websites to another. This may be required as a part of an upgrade keeping the old URL but website should be served from new URL. This document would brief you on different ways ca…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now