成都网站建设设计

将想法与焦点和您一起共享

linux无法重启php服务怎么办

本文操作环境:centos 6.5系统、php7.1版、DELL G3电脑

成都创新互联公司是一家专业提供白云企业网站建设,专注与成都做网站、成都网站建设、HTML5建站、小程序制作等业务。10年已为白云众多企业、政府机构等服务。创新互联专业网络公司优惠进行中。

linux无法重启php服务怎么办?

linux中root无法启动php-fpm问题解决办法:

centos 6.5 64位的机器,用yum装的php-fpm,因为特殊原因需要用root账号启动php-fpm,但是发现,启动不了。

1,修改user和group

# vim /etc/php-fpm.d/www.conf   
  
; RPM: apache Choosed to be able to access some dir as httpd  
user = root        //改为root  
; RPM: Keep a group allowed to write in log dir.  
group = root      //改为root

重启php-fpm时,报以下错误

ERROR: [pool www] please specify user and group other than root
[09-Jan-2015 16:54:26] ERROR: FPM initialization failed

解决办法:

# /etc/init.d/php-fpm stop   //关闭php-fpm  
  
# nohup /usr/sbin/php-fpm -R >/dev/null 2>&1 &  
  
# echo "nohup /usr/sbin/php-fpm -R >/dev/null 2>&1 &" >> /etc/rc.local  //加入开机启动

本文名称:linux无法重启php服务怎么办
当前路径:http://chengdu.cdxwcx.cn/article/copoids.html