【求助】安装LNMP结果显示PHP安装失败
netstat -tunpl显示结果:Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN 21939/mysqld
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 21510/nginx.conf
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1128/sshd
udp 0 0 0.0.0.0:68 0.0.0.0:* 639/dhclient
udp 0 0 172.19.153.165:123 0.0.0.0:* 729/ntpd
udp 0 0 127.0.0.1:123 0.0.0.0:* 729/ntpd
udp 0 0 0.0.0.0:123 0.0.0.0:* 729/ntpd
udp6 0 0 :::123 :::* 729/ntpd
打开IP地址显示“LNMP一键安装包安装成功!”
但首页上的“探针”“phpinfo”“phpMyAdmin”都无法正常打开,显示“502 bad gateway”.
总之,种种迹象表明,PHP安装失败了。我使用“sh一键web安装”也出现同样问题。
现在把lnmp-install.log放在附件,麻烦大家帮助。谢谢。
lnmp-install.log: /bin/bash /root/lnmp1.3-full/src/php-7.0.7/libtool --silent --preserve-dup-deps --mode=compile cc -I/root/lnmp1.3-full/src/php-7.0.7/ext/gd/libgd -DHAVE_LIBPNG -DHAVE_LIBJPEG -DHAVE_LIBFREETYPE -DENABLE_GD_TTF -Iext/gd/ -I/root/lnmp1.3-full/src/php-7.0.7/ext/gd/ -DPHP_ATOM_INC -I/root/lnmp1.3-full/src/php-7.0.7/include -I/root/lnmp1.3-full/src/php-7.0.7/main -I/root/lnmp1.3-full/src/php-7.0.7 -I/root/lnmp1.3-full/src/php-7.0.7/ext/date/lib -I/usr/include/libxml2 -I/usr/local/freetype/include/freetype2 -I/usr/local/freetype/include -I/root/lnmp1.3-full/src/php-7.0.7/ext/mbstring/oniguruma -I/root/lnmp1.3-full/src/php-7.0.7/ext/mbstring/libmbfl -I/root/lnmp1.3-full/src/php-7.0.7/ext/mbstring/libmbfl/mbfl -I/usr/local/include -I/root/lnmp1.3-full/src/php-7.0.7/ext/sqlite3/libsqlite -I/root/lnmp1.3-full/src/php-7.0.7/ext/zip/lib -I/root/lnmp1.3-full/src/php-7.0.7/TSRM -I/root/lnmp1.3-full/src/php-7.0.7/Zend -I/usr/local/include -g -O2 -fvisibility=hidden -c /root/lnmp1.3-full/src/php-7.0.7/ext/gd/libgd/gd_png.c -o ext/gd/libgd/gd_png.lo
In file included from /usr/include/png.h:317:0,
from /root/lnmp1.3-full/src/php-7.0.7/ext/gd/libgd/gd_png.c:10:
/usr/include/zlib.h:86:5: error: unknown type name 鈥榸_const鈥? z_const Bytef *next_in; /* next input byte */
^
/usr/include/zlib.h:86:19: error: expected 鈥?鈥? 鈥?鈥? 鈥?鈥? 鈥榼鈥?or 鈥榑_attribute__鈥?before 鈥?鈥?token
z_const Bytef *next_in; /* next input byte */
^
In file included from /usr/include/zlib.h:34:0,
from /usr/include/png.h:317,
from /root/lnmp1.3-full/src/php-7.0.7/ext/gd/libgd/gd_png.c:10:
/usr/include/zlib.h:1025:29: error: unknown type name 鈥榸_const鈥? typedef unsigned (*in_func) OF((void FAR *,
^
/usr/include/zlib.h:1029:33: error: unknown type name 鈥榠n_func鈥? ZEXTERN int ZEXPORT inflateBack OF((z_streamp strm,
^
In file included from /usr/include/png.h:317:0,
from /root/lnmp1.3-full/src/php-7.0.7/ext/gd/libgd/gd_png.c:10:
/usr/include/zlib.h:1349:32: error: expected 鈥?鈥? 鈥?鈥? 鈥?鈥? 鈥榓sm鈥?or 鈥榑_attribute__鈥?before 鈥榋_ARG鈥? ZEXTERN int ZEXPORTVA gzprintf Z_ARG((gzFile file, const char *format, ...));
^
/usr/include/zlib.h:1673:5: error: unknown type name 鈥榸_off64_t鈥? z_off64_t pos;
^
/usr/include/zlib.h:1748:15: error: unknown type name 鈥榸_crc_t鈥? ZEXTERN const z_crc_t FAR * ZEXPORT get_crc_table OF((void));
^
/usr/include/zlib.h:1758:44: error: expected 鈥?鈥? 鈥?鈥? 鈥?鈥? 鈥榓sm鈥?or 鈥榑_attribute__鈥?before 鈥榋_ARG鈥? ZEXTERN int ZEXPORTVA gzvprintf Z_ARG((gzFile file,
^
Makefile:937: recipe for target 'ext/gd/libgd/gd_png.lo' failed
make: *** Error 1
php安装时报错,不清楚具体原因
sh不一定是bash,是不能用的
回复 2# 的帖子
:Q :Q 多谢军哥,问题还没有解决,不知道如何是好了。回复 3# 的帖子
换其他版本或发行版
页:
[1]