编译 PHP 后产生的这些文件是干嘛的 ?
[root@localhost ~]# ls /usr/src/php-5.6.9/sapi/fpm/
config.m4 init.d.php-fpm.in php-fpm.8 php-fpm.service tests
CREDITS LICENSE php-fpm.8.in php-fpm.service.in
fpm Makefile.frag php-fpm.conf status.html
init.d.php-fpm php-fpm php-fpm.conf.in status.html.in
[root@localhost ~]#
编译 PHP 后产生的这些文件是干嘛的 , 是不是可以 使用 (CentOS7)
systemctl start php-fpm
或者
service php-fpm start
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
php-fpm 是生成的二进制程序。
php-fpm.conf 是php-fpm的配置。
init.d.php-fpm 是传统的init服务脚本。
php-fpm.service 则是systemd的服务脚本。
status.html 用于查看php-fpm的运行时信息。
传统的init服务:
cp init.d.php-fpm /etc/rc.d/init.d/php-fpm
启动服务:
sudo service php-fpm start
开机自启动:
chkconfig php-fpm on
Redhat 7 引入了systemd服务管理:
cp php-fpm.service /usr/lib/systemd/system
启动服务:
sudo systemctl start php-fpm.service
开机自启动:
sudo systemctl enable php-fpm.service
php-fpm.conf 里配置 pm.status_path = /status

nginx.conf 里配置:
location /status {
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_index index.php;
fastcgi_pass 127.0.0.1:9000;
}
status.html里填入:
http://www.example.com/status?json&full
就可以看到:
要
以后才可以用吧,像
php-fpm
是编译生成的文件。php-fpm.conf
是配置文件,正常情况下执行install的时候,会把文件复制到相应的目录。