Bug 53722 - when -D NO_DETACH is used, no PID file should be created
Summary: when -D NO_DETACH is used, no PID file should be created
Alias: None
Product: Apache httpd-2
Classification: Unclassified
Component: Core (show other bugs)
Version: 2.4-HEAD
Hardware: PC Linux
: P2 normal (vote)
Target Milestone: ---
Assignee: Apache HTTPD Bugs Mailing List
Depends on:
Reported: 2012-08-15 00:14 UTC by Cristian Rodríguez
Modified: 2019-06-21 09:02 UTC (History)
0 users


Note You need to log in before you can comment on or make changes to this bug.
Description Cristian Rodríguez 2012-08-15 00:14:20 UTC
if the server is started with -D NO_DETACH , no PID files should be created and the PidFile directive should be ignored.

Modern init like systemd have his own process indentifier tracking capabilities and by design cannot "forget" what the process ID is neither crazy childs can escape its control, in such scenario, pid files are completely useless.
Comment 1 Joe Orton 2019-06-21 09:02:16 UTC
"httpd -k reload" etc rely on reading the pid to signal the server.  You could remove "httpd -k" support entirely, drop the pidfiles and make a very pure systemd-only-controllable service; this might be worthwhile tho a bit of a culture shock.  So I'd say patches welcome - but the code is working as designed currently.