diff options
author | Sanju Rakonde <srakonde@redhat.com> | 2019-11-25 16:35:42 +0530 |
---|---|---|
committer | MOHIT AGRAWAL <moagrawa@redhat.com> | 2019-12-05 07:47:12 +0000 |
commit | 6015ab7d8b37388e836f36a315af54f019839d91 (patch) | |
tree | 638055a46595001d99d2e2b986fda5a734017fec /extras | |
parent | d29b8e62a186770d26bf7daf3437d899ae00a0da (diff) |
glusterd: start glusterd automatically on abnormal shutdown
If glusterd crashes or goes down abnormally, systemd should
automatically bring the glusterd up.
With this change, systemd brings glusterd up for atmost 3 times
within time period of 1 hour. If the limit exceeds, we have to
start the glusterd manually and reset the failure count using
systemctl reset-failed.
credits: John Strunk <jstrunk@redhat.com>
fixes: bz#1776264
Change-Id: I312d243652fb13ba028814a2ea615b67e3b10b6a
Signed-off-by: Sanju Rakonde <srakonde@redhat.com>
Diffstat (limited to 'extras')
-rw-r--r-- | extras/systemd/glusterd.service.in | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/extras/systemd/glusterd.service.in b/extras/systemd/glusterd.service.in index 7c818221845..af10ea18c14 100644 --- a/extras/systemd/glusterd.service.in +++ b/extras/systemd/glusterd.service.in @@ -15,6 +15,11 @@ ExecStart=@prefix@/sbin/glusterd -p @localstatedir@/run/glusterd.pid --log-leve KillMode=process TimeoutSec=300 SuccessExitStatus=15 +Restart=on-abnormal +RestartSec=60 +StartLimitBurst=3 +StartLimitIntervalSec=3600 +StartLimitInterval=3600 [Install] WantedBy=multi-user.target |