[monit/el5] Fix init script to use correct pidfile
Maxim Burgerhout
wzzrd at fedoraproject.org
Wed Jul 11 21:11:35 UTC 2012
commit 5a3ae75cea5e69c01a4e2cecbc3dde77cd3c1131
Author: Maxim Burgerhout <maxim at wzzrd.com>
Date: Wed Jul 11 23:10:26 2012 +0200
Fix init script to use correct pidfile
- Use that pidfile to kill the daemon instead of the process name #676178
monit-sysv-initscript | 5 +++--
monit.spec | 6 +++++-
2 files changed, 8 insertions(+), 3 deletions(-)
---
diff --git a/monit-sysv-initscript b/monit-sysv-initscript
index 85f1651..29de19b 100644
--- a/monit-sysv-initscript
+++ b/monit-sysv-initscript
@@ -9,7 +9,7 @@
#
# processname: monit
# config: /etc/monit.conf
-# pidfile: /var/run/monit
+# pidfile: /var/run/monit.pid
# Short-Description: Monit is a system monitor
# Source function library.
@@ -17,6 +17,7 @@
### Default variables
CONFIG="/etc/monit.conf"
+pidfile="/var/run/monit.pid"
prog="monit"
# Check if requirements are met
@@ -36,7 +37,7 @@ start() {
stop() {
echo -n $"Shutting down $prog: "
- killproc $prog
+ killproc -p ${pidfile}
RETVAL=$?
echo
[ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/$prog
diff --git a/monit.spec b/monit.spec
index 2d9efdd..7d94eca 100644
--- a/monit.spec
+++ b/monit.spec
@@ -1,6 +1,6 @@
Name: monit
Version: 4.10.1
-Release: 8%{?dist}
+Release: 9%{?dist}
Summary: Manages and monitors processes, files, directories and devices
Group: Applications/Internet
@@ -96,6 +96,10 @@ fi
%{_mandir}/man1/monit.1*
%changelog
+* Wed Jul 11 2012 Maxim Burgerhout <wzzrd at fedoraproject.org> - 4.10.1-9
+- Fix init script to use correct pidfile
+- Use that pidfile to kill the daemon instead of the process name #676178
+
* Mon Dec 22 2008 Stewart Adam <s.adam at diffingo.com> 4.10.1-8
- Tweak configuration defaults: include /etc/monit.d/*, log to /var/log/monit
and set daemon time to 60s
More information about the scm-commits
mailing list