打印

LNMP一键安装包的Nginx 502 Bad Gateway错误可能原因及解决方法

lnmp1.2安装完毕后打不开phpmyadmin

按照教程安装lnmp1.2,安装完毕后nginx页面能打开,在ip地址后加phpmyadmin打不开phpmyadmin,系统是centos7,附安装日志
附件: 您所在的用户组无法下载或查看附件

TOP

在配置Nginx的http目录访问认证访问目录总是502,在网上找了一圈未果,最后又找了回来,原来是fastcgi_pass的问题,非常感谢。

TOP

刚装的环境,一直是502,访问不了php文件。

[09-Mar-2017 00:09:25] ERROR: An another FPM instance seems to already listen on /tmp/php-cgi.sock
[09-Mar-2017 00:09:25] ERROR: FPM initialization failed
[09-Mar-2017 09:10:27] NOTICE: Finishing ...
[09-Mar-2017 09:10:27] NOTICE: exiting, bye-bye!
[09-Mar-2017 09:10:28] NOTICE: fpm is running, pid 18980
[09-Mar-2017 09:10:28] NOTICE: ready to handle connections
这是php-fpm日志,军哥帮忙看看什么原因。之前装过一次lnmp,php是5.6的,也是502。然后卸载重新装了一遍,还是同样的问题。


/etc/init.d/php-fpm status
php-fpm (pid 18980) is running...

php-fpm也是能启动的。

php-fpm.conf的配置文件是这样的
[global]
pid = /usr/local/php/var/run/php-fpm.pid
error_log = /usr/local/php/var/log/php-fpm.log
log_level = notice

[www]
listen = /tmp/php-cgi.sock
listen.backlog = -1
listen.allowed_clients = 127.0.0.1
listen.owner = www
listen.group = www
listen.mode = 0666
user = www
group = www
pm = dynamic
pm.max_children = 60
pm.start_servers = 30
pm.min_spare_servers = 30
pm.max_spare_servers = 60
request_terminate_timeout = 100
request_slowlog_timeout = 0
slowlog = var/log/slow.log

TOP