启动PHP报错ERROR: [pool www] cannot get uid for user ‘@php_fpm_user@’

2022-06-30 18:28:08 浏览数 (1)

当编译并安装好php后,用以下命令启动

sudo ./sbin/php-fpm

然后报出这样的错误:

www.linuxidc.com @linux ~/php5 % sudo ./sbin/php-fpm

[02-Mar-2014 09:11:26] ERROR: [pool www] cannot get uid for user '@php_fpm_user@'

[02-Mar-2014 09:11:26] ERROR: FPM initialization failed

修改php的配制文件php-fpm.conf (在安装目录的etc子目录下)

www.linuxidc.com @linux ~/php5/etc % sudo vi php-fpm.conf

www.linuxidc.com @linux ~/php5/etc % sudo vi php-fpm.conf

将@php_fpm_user@改为当前系统的用户名,如下图,然后重新启动就ok了

0 人点赞