Hello, Thanks a lot for your answer and micahl schmidt. I made several more tests and I wonder whether there are at all any such tasks with which systemd uses the release agents.
Most of the services uses one process (this is at least what I see when running "cat task" from most systemd service folders). So I assume probably most of them indeed send SIGCHLD to systemd which is their parent process. (unless someone will pop up and say that are there any known exceptions to this; I would like to hear about such exceptions) There are some exceptions. Specifically I tried with rsyslog.services and polkit.service. These two services has each several services in tasks. with rsyslog.service: [root@h rsyslog.service]# pstree -p 530 rsyslogd(530)─┬─{rsyslogd}(582) ├─{rsyslogd}(583) └─{rsyslogd}(584) ann kill -9 584 gives: Apr 17 17:59:11 localhost rsyslogd: [origin software="rsyslogd" swVersion="7.2.5" x-pid="8065" x-info="http://www.rsyslog.com"] start Apr 17 17:59:11 localhost systemd[1]: rsyslog.service: main process exited, code=killed, status=9/KILL Apr 17 17:59:11 localhost systemd[1]: Unit rsyslog.service entered failed state Apr 17 17:59:11 localhost systemd[1]: Starting System Logging Service... Apr 17 17:59:11 localhost systemd[1]: Started System Logging Service. The same for polkit: pstree -p 600 polkitd(600)─┬─{polkitd}(608) ├─{polkitd}(611) ├─{polkitd}(614) └─{polkitd}(615) but kill -9 698 did trigger a KILL signal in /var/log/messages: (and from the ps command we can see that 608 was created by 600). this is what I see in kernel log: ... Apr 17 18:02:48 localhost systemd[1]: polkit.service: main process exited, code=killed, status=9/KILL Apr 17 18:02:48 localhost systemd[1]: Unit polkit.service entered failed state ... and of course that systemd-cgroups-agent is missing: ls /usr/lib/systemd/systemd-cgroups-agent ls: cannot access /usr/lib/systemd/systemd-cgroups-agent: No such file or directory It could be that this threads do send SIGCHLD to systemd. (probably this is the case). I wonder if someone knows about a service when a SIGCHLD is not sent? Or maybe the releas agent is only good for the case when the cgroup runs empty, when all the "grandchildren" are dead (as the case Lennart mentioned). rgs Kevin On Wed, Apr 17, 2013 at 5:48 PM, Lennart Poettering <lenn...@poettering.net> wrote: > On Tue, 16.04.13 20:45, Kevin Wilson (wkev...@gmail.com) wrote: > >> cat /sys/fs/cgroup/systemd/system/bluetooth.service/tasks >> 671 >> >> Apr 16 20:40:05 localhost systemd[1]: bluetooth.service: main process >> exited, code=killed, status=9/KILL >> Apr 16 20:40:05 localhost systemd[1]: Unit bluetooth.service entered >> failed state >> >> And with mcelog it was the same: >> >> ... >> Apr 16 20:33:46 localhost systemd[1]: mcelog.service: main process >> exited, code=killed, status=9/KILL >> Apr 16 20:33:46 localhost systemd[1]: Unit mcelog.service entered failed >> state >> ... >> >> both folders, bluetooth.service and mcelog.service (under >> /sys/fs/cgroup/systemd/system/) were removed. >> >> How come ? could it be that the messages to the DBus are not sent >> by systemd-cgroups-agent? > > systemd gets both SIGCHLD for its children and cgroup events for the > cgroups they are running in. What you are seening above is the SIGCHLD > working. > > SIGCHLD we only get for the processes we ourselves started, but usually > not for processes started by them. SIGCHLD contains exit status > information, such as return code, or signal information. > > The cgroup events we get when the cgroup runs empty, when all our > "grandchildren" are dead, too. It doesn't contain any exist status > information, so is not as nice. > > Lennart > > -- > Lennart Poettering - Red Hat, Inc. _______________________________________________ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel