Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

WARNING: Module mcrypt ini file doesn't exist under /etc/php/7.2/mods-available

I've been trying to install phpmyadmin in Ubuntu 16.04.3 LTS having a lamp installed, php 7.2, mysql Ver 15.1 Distrib 10.2.12-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2 and apache2.

and I am following this article from digitalOcean, but when I came to the part that I need to run sudo phpenmod mcrypt I got a message saying..

WARNING: Module mcrypt ini file doesn't exist under /etc/php/7.2/mods-available

I am doing this on ubuntu installed in godaddy

Can you give best solution for this?

like image 747
Fil Avatar asked Jan 21 '18 04:01

Fil


2 Answers

Pointing to php7.1-mcrypt with php7.2 will solve the issue here. Below are the steps to configure 7.1 version mcrypt with php7.2

Install php7.1-mcrypt

sudo apt install php7.1-mcrypt


Create symbolic link to php7.1-mcrypt

sudo ln -s /etc/php/7.1/mods-available/mcrypt.ini /etc/php/7.2/mods-available/


Enable mcrypt extension

sudo phpenmod mcrypt


Restart the FastCGI Process Manager service

sudo service php7.2-fpm restart


Note:
The above solution is a workaround to enable mcrypt in php7.2 through apt till php7.2-mcrypt is not available.

like image 111
Somnath Sinha Avatar answered Sep 22 '22 23:09

Somnath Sinha


for php-7.3 like mentioned above i had to execute this command

sudo ln -s /etc/php/7.0/mods-available/mcrypt.ini /etc/php/7.3/mods-available/ cause the version 7.0 comes by default.

like image 45
oussama benounnas Avatar answered Sep 19 '22 23:09

oussama benounnas