Archiv für Dezember 27, 2016

wdlinux 3.0 php 502

wget http://www.kscub.com/share/mhash-0.9.9.9.tar.gz
wget http://www.kscub.com/share/libmcrypt-2.5.8.tar.gz

 

Lösungen:

A、Erster Blick auf den Beginn des Falles php-fpm:(Am Ende ist nicht die Ursache des Problems)

1
2
3
4
5
6
7
8
[root@localhost ~]# find / -name php-fpm #查看php-fpm
/www/wdlinux/init.d/php-fpm
/www/wdlinux/nginx_php-5.2.17/sbin/php-fpm
[root@localhost ~]# /www/wdlinux/init.d/php-fpm start #启动一下php-fpm 下面报错了(缺少包mhash)
Starting php_fpm /www/wdlinux/nginx_php-5.2.17/bin/php-cgi:
error while loading shared libraries:
libmhash.so.2: cannot open shared object file: No such file or directory failed

zwei、Herunterladen mhash Paket:

wget http://www.kscub.com/share/mhash-0.9.9.9.tar.gz

 

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
[root@localhost ~]# ls #查看一下上传的包
mhash-0.9.9.9.tar.gz
[root@localhost ~]# tar xf mhash-0.9.9.9.tar.gz #解压mhash-0.9.9.9.tar.gz包
[root@localhost ~]# cd mhash-0.9.9.9 #进入到解压后生成的mhash-0.9.9.9目录中去
[root@localhost mhash-0.9.9.9]# ./configure #配置,检测安装环境
[root@localhost mhash-0.9.9.9]# make && make install #编译 && 安装
[root@localhost mhash-0.9.9.9]# ln -s /usr/local/lib/libmhash.so.2 /usr/lib/libmhash.so.2
[root@localhost mhash-0.9.9.9]# vim /etc/ld.so.conf.d/mhash.conf #新建的一个配置文件,往里写入:/usr/lib/
[root@localhost mhash-0.9.9.9]# cat /etc/ld.so.conf.d/mhash.conf #里面就只有:/usr/lib/
/usr/lib/
[root@localhost mhash-0.9.9.9]# ldconfig
[root@localhost mhash-0.9.9.9]# /www/wdlinux/init.d/php-fpm start #再启动一下php-fpm,还是报缺少包
Starting php_fpm /www/wdlinux/nginx_php-5.2.17/bin/php-cgi:
error while loading shared libraries:
libmcrypt.so.4: cannot open shared object file: No such file or directory

drei、Download mcrypt Paket:

wget http://www.kscub.com/share/libmcrypt-2.5.8.tar.gz

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
[root@localhost ~]# ls #查看一下上传的包
libmcrypt-2.5.8.tar.gz
[root@localhost ~]# tar xf libmcrypt-2.5.8.tar.gz #解压libmcrypt-2.5.8.tar.gz包
[root@localhost ~]# cd libmcrypt-2.5.8 #进入到解压后生成的libmcrypt-2.5.8目录中去
[root@localhost libmcrypt-2.5.8]# ./configure #配置,检测安装环境
[root@localhost libmcrypt-2.5.8]# make && make install #编译 && 安装
[root@localhost libmcrypt-2.5.8]# ln -s /usr/local/lib/libmcrypt.so.4 /usr/lib/libmcrypt.so.4
[root@localhost libmcrypt-2.5.8]# ln -s /usr/local/lib/libmcrypt.so.4 /usr/lib64/libmcrypt.so.4
[root@localhost libmcrypt-2.5.8]# /www/wdlinux/init.d/php-fpm start #再次启动php-fpm,成功
Starting php_fpm don
[root@localhost libmcrypt-2.5.8]# reboot #重新开机

Bemerkungen