Home > Backend Development > PHP Tutorial > centos7 - centos 7.2 /var/run/php-fpm/php-fpm.sock不存在

centos7 - centos 7.2 /var/run/php-fpm/php-fpm.sock不存在

WBOY
Release: 2016-06-06 20:13:05
Original
3270 people have browsed it

要在nginx中配置重写规则,其中有这么一句:

<code>fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock</code>
Copy after login
Copy after login

可是在centos7.2中,这个路径没有这个文件,只有一个php-fpm.pid文件,那么上面这个文件在哪里?

回复内容:

要在nginx中配置重写规则,其中有这么一句:

<code>fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock</code>
Copy after login
Copy after login

可是在centos7.2中,这个路径没有这个文件,只有一个php-fpm.pid文件,那么上面这个文件在哪里?

find / -name "*php*.sock"找一下sock文件的位置,如果没找到的话就是没配置Unix Socket,只能访问TCP端口,可以为改为fastcgi_pass 127.0.0.1:9000

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template