Re: Mac OS X Yosemite 10.10.1, Apache 2.4.9
Apache 2.4.9 seems to ignore the PidFile directive, and always creates a process id file at /var/run/httpd.pid. This makes it impossible to launch multiple instances of httpd, each listening on a different port. Apache 2.2.26, for example, did not have this problem.
So see for yourself:
1) Modify Apache's "default" Mac OS X configuration file, /etc/apache2/httpd.conf, to include (just after ServerRoot) a directive such as:
PidFile "/var/log/apache2/apache.pid"
2) Start Apache thusly:
sudo apachectl start
3) Observe that the specified .pid file is missing and instead, Apache has created /var/run/httpd.pid.
How to fix?