On Do, 17.05.18 11:33, Reindl Harald (h.rei...@thelounge.net) wrote:

> > but that busy waits. Is there any option to replace this hack via a
> > native systemd solution, like explicitly waiting for the pid file to
> > appear before considering the unit ready?
> 
> this is a bug in nginx
> 
> however, after many years with systemd on Fedora one needs yet to show
> me a service where you can't simply remove the PIDFile line and you are done

systemd is able to guess the main PID of a process in many cases, but
this cannot work in all cases, because from the outside we have no
clue what might be the main process and what is not. In particular
HTTP servers which fork off multiple worker processes are candidates
where systemd won't guess right, because there's ambiguity as there
are likely multiple processes around after start.

Hence, yes, ideally all services would use Type=simple or
Type=notify. But if they don't they should use Type=forking and that
only in combination with PIDFile=, otherwise service management
becomes black magic...

Lennart

-- 
Lennart Poettering, Red Hat
_______________________________________________
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel

Reply via email to