summaryrefslogtreecommitdiffstats
path: root/system
diff options
context:
space:
mode:
authorMichael Johnson <nightexcessive@users.noreply.github.com>2016-05-08 12:10:46 -0400
committerMichael Johnson <nightexcessive@users.noreply.github.com>2016-05-08 12:10:46 -0400
commite55f919b7baa32dd3b2e6a07223002ea693f6ebe (patch)
tree646ea8d3aed58666cd69bac4b8fa4e36c02db752 /system
parent0ec2db444011f5b6ebf41dab45502c27cd544af2 (diff)
Let systemd handle killing the processes
By setting `KillMode` to `mixed`, systemd will send `KillSignal` to the main process. It will then wait `TimeoutStopSec` and then send `SIGKILL` to all processes in the cgroup. This appears to be the desired behavior.
Diffstat (limited to 'system')
-rw-r--r--system/netdata.service.in3
1 files changed, 2 insertions, 1 deletions
diff --git a/system/netdata.service.in b/system/netdata.service.in
index bc26cc9dcc..91db6122d8 100644
--- a/system/netdata.service.in
+++ b/system/netdata.service.in
@@ -9,7 +9,8 @@ User=root
Group=root
PIDFile=@localstatedir_POST@/run/netdata.pid
ExecStart=@sbindir_POST@/netdata -pidfile @localstatedir_POST@/run/netdata.pid
-ExecStop=/bin/kill -SIGTERM $MAINPID
+KillMode=mixed
+KillSignal=SIGTERM
TimeoutStopSec=30
[Install]