Re-watching pids on cgroup v1 (needed because of unreliability of cgroup empty notifications in containers) is handled bellow at the end of service_sigchld_event() and depends on value main_pid_known flag. In CentOS Stream 8 container on cgroup v1 the stop action would get stuck indefinitely on unit like this, $ cat /run/systemd/system/foo.service [Service] ExecStart=/bin/bash -c 'trap "nohup sleep 1 & exit 0" TERM; sleep infinity' ExecStop=/bin/bash -c 'kill -s TERM $MAINPID' TimeoutSec=0 However, upstream works "fine" because in upstream version of systemd we actually never wait on processes killed in containers and proceed immediately to sending SIGKILL hence re-watching of pids in the cgroup is not necessary. But for the sake of correctness we should merge the patch also upstream.
System and Service Manager
Details
Most documentation is available on systemd's web site.
Assorted, older, general information about systemd can be found in the systemd Wiki.
Information about build requirements is provided in the README file.
Consult our NEWS file for information about what's new in the most recent systemd versions.
Please see the Code Map for information about this repository's layout and content.
Please see the Hacking guide for information on how to hack on systemd and test your modifications.
Please see our Contribution Guidelines for more information about filing GitHub Issues and posting GitHub Pull Requests.
When preparing patches for systemd, please follow our Coding Style Guidelines.
If you are looking for support, please contact our mailing list or join our IRC channel.
Stable branches with backported patches are available in the stable repo.
