PHP-FPM Stop/Reload Issues on Mac Lion (OSX 10.7)
13,307
Solution 1
Alternatively, using the USR2 signal makes php-fpm reload its configuration file:
kill -USR2 `cat /usr/local/var/run/php-fpm.pid`
Solution 2
You can use Lanchctl:
Stop:
launchctl unload -w ~/Library/LaunchAgents/homebrew-php.josegonzalez.php55.plist
Start:
launchctl load -w ~/Library/LaunchAgents/homebrew-php.josegonzalez.php55.plist
Adapt the version number "php55" to your environment.
Solution 3
sudo killall php-fpm
Use this command, you can kill php-fpm. I have tried, it works.
System: Mac OS X 10.11.4
Author by
Splashlin
Updated on June 14, 2022Comments
-
Splashlin almost 2 years
I'm setting up php-fpm on my machine and I installed it using homebrew (specifically homebrew-alt). Everything installed fine and if I open up the terminal and type the command "php-fpm" it starts up fine. Unfortunately if I try to run any commands such as "php-fpm stop" I get the message below. Does anyone have any idea what may be causing this or how I could get it working? If I try killing the process with the kill command it just seems to automatically restart itself.
Usage: php [-n] [-e] [-h] [-i] [-m] [-v] [-t] [-p <prefix>] [-g <pid>] [-c <file>] [-d foo[=bar]] [-y <file>] -c <path>|<file> Look for php.ini file in this directory -n No php.ini file will be used -d foo[=bar] Define INI entry foo with value 'bar' -e Generate extended information for debugger/profiler -h This help -i PHP information -m Show compiled in modules -v Version number -p, --prefix <dir> Specify alternative prefix path to FastCGI process manager (default: /usr/local/Cellar/php/5.3.8). -g, --pid <file> Specify the PID file location. -y, --fpm-config <file> Specify alternative path to FastCGI process manager config file. -t, --test Test FPM configuration and exit
-
William Turrell about 10 yearsThis is the proper, clean way of doing it (& you'll get instructions to this effect when installing or upgrading PHP with Homebrew).
-
NotoriousWebmaster about 10 yearsThis works for me, except for the tilde. When I remove the tilde, it works.
-
DigitalDesignDj over 8 yearsI had to look in
~/Library/LaunchAgents/
to find the correct .plist for the homebrew php I've installed