Mcrypt extension not recognized by php5-fpm

Bug #1241286 reported by Marc-François Cochaux-Laberge on 2013-10-18
This bug report is a duplicate of:  Bug #1243568: put ini in correct path. Edit Remove
This bug affects 17 people
Affects Status Importance Assigned to Milestone
php-mcrypt (Ubuntu)

Bug Description

I installed php5-fpm, php5-mcrypt and nginx.

phpinfo() tells me that mcrypt in installed, but it is impossible to use it. I get the "Laravel requires the Mcrypt PHP extension. " error message when trying to use an application made with Laravel.

I installed these packages a few times in the past and it happened only in Ubuntu 13.10.

ProblemType: Bug
DistroRelease: Ubuntu 13.10
Package: php5-mcrypt 5.4.6-0ubuntu3
ProcVersionSignature: Ubuntu 3.11.0-12.19-generic 3.11.3
Uname: Linux 3.11.0-12-generic x86_64
ApportVersion: 2.12.5-0ubuntu2
Architecture: amd64
Date: Thu Oct 17 21:26:53 2013
 gcc-4.8-base 4.8.1-10ubuntu8
 libc6 2.17-93ubuntu4
 libgcc1 1:4.8.1-10ubuntu8
 libmcrypt4 2.5.8-3.1
 multiarch-support 2.17-93ubuntu4
InstallationDate: Installed on 2013-10-17 (0 days ago)
InstallationMedia: Ubuntu 13.10 "Saucy Salamander" - Release amd64 (20131016.1)
MarkForUpload: True
SourcePackage: php-mcrypt
UpgradeStatus: No upgrade log present (probably fresh install)

description: updated

This is duplicate of #1240590
You can fix manually using command below

Make symbolic link to ini files in mods-available
# ln -s /etc/php5/conf.d/mcrypt.ini /etc/php5/mods-available
Enable mods
# php5enmod mcrypt

Finaly, restart your php related service.

I made a typo in symbolic link command, fixed below:

Make symbolic link to ini files in mods-available
# ln -s /etc/php5/conf.d/mcrypt.ini /etc/php5/mods-available/mcrypt.ini
Enable mods
# php5enmod mcrypt

Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in php-mcrypt (Ubuntu):
status: New → Confirmed
echo (soo-yy) wrote :

I'm using ubuntu 14.04 LTS, PHP 5.5.9.

I can't find the conf.d folder under /etc/php5/ .

The following works for me:

Create a new file mcrypt.ini under /etc/php5/mods-available/

Enter this line in mcrypt.ini:

Enable mods
$ php5enmod mcrypt

Restart Apache2

Now the warning about missing Mcrypt PHP extension is gone.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Bug attachments