systemd: rewatch pids under cgroup v1 when sigchld of processes more than main pid...
authorchenjiayi <chenjiayi22@huawei.com>
Wed, 18 Sep 2024 03:12:34 +0000 (11:12 +0800)
committerLennart Poettering <lennart@poettering.net>
Wed, 18 Sep 2024 08:13:20 +0000 (10:13 +0200)
commit4fc8a63f9e193e1c849dc3dc1abdc623db804770
tree5522d2eee72bb7e3a963bb79c77bd1f594ecc057
parentdfb3155419c5c1bfb9cd2c8735b46c7724d171c4
systemd: rewatch pids under cgroup v1 when sigchld of processes more than main pid and control pid is captured

If `Delegate` is configured in service, cgroup agent will never send out
any datagram as .control subcgroup is generated. Thus systemd will watch
all processes on the cgroup hierarchy for SIGCHLD to deal with unreliable
cgroup notifications.

In this way, systemd should rewatch all processes when any SIGCHLD is
captured, more than the control pid or main pid.
src/core/service.c