[systemd-devel] 回复: 回复: [systemd-de vel] systemctl can't execute stop actually,whenservice is started by other way

Lennart Poettering lennart at poettering.net
Thu Jun 29 08:29:37 UTC 2017

On Thu, 29.06.17 10:05, Oliver Neukum (oneukum at suse.com) wrote:

> Am Mittwoch, den 28.06.2017, 13:29 +0200 schrieb Lennart Poettering:
> > Well, it's a service manager. As such it keeps track of services,
> > knows when they are started and when they aren't. Why would it stop
> > services that aren't started?
> Because you command it to do so.

Because things are technically designed that way. When systemd manages
services it does so ensuring it will get SIGCHLD events for them. it
will also run them in a cgroup, so that it can monitor its lifetime by
enumerating the cgroup's contents, and getting events from it.

Now, if you start stuff outside of systemd nothing of that is
available, so systemd wouldn#t know that is running, and it
couldn't properly stop anything because it can't get ahold of the
processes to terminate.


Lennart Poettering, Red Hat

More information about the systemd-devel mailing list