nginx 不解析php文件 502
安装的nginx默认侦听的是9000端口
查询9000端口是否出于侦听状态
netstat -antp | grep :9000
查询之后发现没有查到,查看php-fpm.conf文件
cat /usr/local/php/etc/php-fpm.conf
修改nginx配置
location ~ \.php$ { fastcgi_pass unix:/dev/shm/php-cgi.sock; #127.0.0.1:9000 fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; }