Reputation: 211
501 25131 1 0 9:31下午 ?? 0:00.37 /usr/local/opt/php/sbin/php-fpm --nodaemonize
501 25136 25131 0 9:31下午 ?? 0:00.00 /usr/local/opt/php/sbin/php-fpm --nodaemonize
501 25137 25131 0 9:31下午 ?? 0:00.00 /usr/local/opt/php/sbin/php-fpm --nodaemonize
501 26377 26220 0 10:32下午 ttys000 0:00.00 grep --color=auto --exclude-dir=.bzr --exclude-dir=CVS --exclude-dir=.git --exclude-dir=.hg --exclude-dir=.svn php-fpm
I modified php-fpm.conf daemonize = no
, when restart php-fpm by
kill -USR2 'cat /usr/local/var/run/php-fpm.pid'
and then I find I can't close php-fpm by
kill -9 25131
I can see fpm restart automatically through the error log:
[26-Sep-2018 23:13:43] NOTICE: [pool www] 'user' directive is ignored when FPM is not running as root
[26-Sep-2018 23:13:43] NOTICE: [pool www] 'user' directive is ignored when FPM is not running as root
[26-Sep-2018 23:13:43] NOTICE: [pool www] 'group' directive is ignored when FPM is not running as root
[26-Sep-2018 23:13:43] NOTICE: [pool www] 'group' directive is ignored when FPM is not running as root
[26-Sep-2018 23:13:43] NOTICE: fpm is running, pid 26948
[26-Sep-2018 23:13:43] NOTICE: ready to handle connections
It will restart with a new PID, I find no master process and dont know what does --nodaemonize
mean.
This problem happened on my macbook just now.
Upvotes: 2
Views: 3396
Reputation: 211
In the dir ~/Library/LaunchAgents
find this file homebrew.mxcl.php.plist
.
Delete it and restart my mac, the problem was resolved.
Upvotes: 12