|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
Patches72575 (last revision 2016-07-11 11:54 UTC by gooh@php.net)Pull Requests
Pull requests:
HistoryAllCommentsChangesGit/SVN commits
[2016-07-11 10:53 UTC] gooh@php.net
-Assigned To:
+Assigned To: gooh
[2016-07-11 11:54 UTC] gooh@php.net
[2016-07-12 08:38 UTC] jpauli@php.net
[2016-07-12 08:38 UTC] jpauli@php.net
-Status: Assigned
+Status: Closed
[2016-10-17 10:11 UTC] bwoebi@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Oct 26 09:00:01 2025 UTC |
Description: ------------ Trying to start PHP-FPM with the --allow-to-run-as-root flag will not work when the user directive is not given in the FPM worker pool configuration. Parsing the config will fail. Consequently, FPM cannot start. The offending code is in /master/sapi/fpm/fpm/fpm_conf.c: 766 /* alert if user is not set only if we are not root*/ 767 if (!wp->config->user && !geteuid()) { 768 zlog(ZLOG_ALERT, "[pool %s] user has not been defined", wp->config->name); 769 return -1; 770 } On a side note: the comment is wrong (should be "if we are root"). Related https://bugs.php.net/bug.php?id=61295 Test script: --------------- Comment the user directive in a worker pool confing. Then try to start php-fpm as root. Actual result: -------------- root@4d9ea34ff691:/var/www/html# php-fpm -D [11-Jul-2016 08:27:46] ALERT: [pool www] user has not been defined [11-Jul-2016 08:27:46] ERROR: failed to post process the configuration [11-Jul-2016 08:27:46] ERROR: FPM initialization failed