Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/236.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Centos 6.7(libmcrypt)上的PHP安装错误_Php_Vagrant_Centos6 - Fatal编程技术网

Centos 6.7(libmcrypt)上的PHP安装错误

Centos 6.7(libmcrypt)上的PHP安装错误,php,vagrant,centos6,Php,Vagrant,Centos6,配置 PHP5.6 Mysql 5.6..x Nginx 1.8.x CentOS 6.7 当我运行yum安装php mcrypt时,我得到了错误消息 Error: Package: php55w-mcrypt-5.5.38-1.w6.x86_64 (webtatic) Requires: libmcrypt.so.4()(64bit) 我尝试将libmcrypt文件复制到lib64中,但也没有显示。不知道为什么,我正在使用 sudo cp /home/vagrant/lib-f

配置

PHP5.6

Mysql 5.6..x

Nginx 1.8.x

CentOS 6.7

当我运行yum安装php mcrypt时,我得到了错误消息

Error: Package: php55w-mcrypt-5.5.38-1.w6.x86_64 (webtatic)
       Requires: libmcrypt.so.4()(64bit)
我尝试将libmcrypt文件复制到lib64中,但也没有显示。不知道为什么,我正在使用

sudo cp /home/vagrant/lib-files/libmcrypt.so.4 /usr/lib64/ 
当我检查我的lib64时,仍然没有结果

我也试过这个。
我也尝试过这个,得到了这个输出。仍然不起作用

sudo yum install php-mcrypt
Loaded plugins: fastestmirror
Setting up Install Process
Loading mirror speeds from cached hostfile
* base: mirror.pac-12.org
 extras: centos.mirrors.my2pro.com
* updates: mirrors.ocf.berkeley.edu
* webtatic: us-east.repo.webtatic.com
Resolving Dependencies
--> Running transaction check
---> Package php56w-mcrypt.x86_64 0:5.6.30-1.w6 will be installed
--> Processing Dependency: libmcrypt.so.4()(64bit) for package:      php56w-mcrypt-5.6.30-1.w6.x86_64
--> Finished Dependency Resolution
Error: Package: php56w-mcrypt-5.6.30-1.w6.x86_64 (webtatic)
       Requires: libmcrypt.so.4()(64bit)

我无法发表评论,因此我将回答,希望能有所帮助:

在我之前的例子中,我们基本上有相同的设置,CentOS、PHP和MySQL

yum -y update
rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm
rpm -Uvh https://mirror.webtatic.com/yum/el6/latest.rpm
yum install php56w php56w-opcache -y
yum install -y php56w-mcrypt

请试试这个。您可以跳过对最新操作系统的更新。

我也尝试过这一点,并获得了此输出。仍然不起作用。这是Centos/6.7提供的PHP版本还是某个第三方软件包?我相信它是Centos@ÁlvaroGonzálezThx bro提供的,这个包rpm-Uvh>很有帮助,对吗