summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: cd7a33e)
raw | patch | inline | side by side (parent: cd7a33e)
author | Sebastian Harl <sh@tokkee.org> | |
Tue, 17 Sep 2013 05:16:36 +0000 (07:16 +0200) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Tue, 17 Sep 2013 05:16:36 +0000 (07:16 +0200) |
… else, a process might be left-over after changing USE_COLLECTDMON and
restarting collectd.
Thanks to Dennis Hoppe for reporting this.
Closes: #704048
restarting collectd.
Thanks to Dennis Hoppe for reporting this.
Closes: #704048
debian/changelog | patch | blob | history | |
debian/collectd-core.collectd.init.d | patch | blob | history |
diff --git a/debian/changelog b/debian/changelog
index de016463b03d9a30d7bd36159fbc68987e7faf59..5c70943f7f9dccb69f79edee06a35cf912ddb1b9 100644 (file)
--- a/debian/changelog
+++ b/debian/changelog
- Let libcollectdclient-dev replace/break collectd-dev (<< 5.2.0-1)
because it ships files previously shipped by that package; thanks to
Andreas Beckmann for reporting this (Closes: #717973).
+ * debian/collectd-core.collectd.init.d:
+ - Do not use different PID files for collectd and collectdmon. Else, a
+ process might be left-over after changing USE_COLLECTDMON and restarting
+ collectd. Thanks to Dennis Hoppe for reporting this (Closes: #704048).
-- Sebastian Harl <tokkee@debian.org> Thu, 02 May 2013 21:22:46 +0200
index dc582e4fa433d931f4848eb27e6550f2ecc24d89..f18b994c316fbf57250db7ec0cd0ebd4a668fa30 100755 (executable)
USE_COLLECTDMON=1
COLLECTDMON_DAEMON=/usr/sbin/collectdmon
-COLLECTDMON_PIDFILE=/var/run/collectdmon.pid
MAXWAIT=30
ulimit -c unlimited
fi
-if test "$USE_COLLECTDMON" == 1; then
- _PIDFILE="$COLLECTDMON_PIDFILE"
-else
- _PIDFILE="$PIDFILE"
-fi
-
# return:
# 0 if config is fine
# 1 if there is a syntax error
fi
if test "$USE_COLLECTDMON" == 1; then
- start-stop-daemon --start --quiet --oknodo --pidfile "$_PIDFILE" \
- --exec $COLLECTDMON_DAEMON -- -P "$_PIDFILE" -- -C "$CONFIGFILE" \
+ start-stop-daemon --start --quiet --oknodo --pidfile "$PIDFILE" \
+ --exec $COLLECTDMON_DAEMON -- -P "$PIDFILE" -- -C "$CONFIGFILE" \
|| return 2
else
- start-stop-daemon --start --quiet --oknodo --pidfile "$_PIDFILE" \
- --exec $DAEMON -- -C "$CONFIGFILE" -P "$_PIDFILE" \
+ start-stop-daemon --start --quiet --oknodo --pidfile "$PIDFILE" \
+ --exec $DAEMON -- -C "$CONFIGFILE" -P "$PIDFILE" \
|| return 2
fi
return 0
# 1 if the daemon was already stopped
# 2 if daemon could not be stopped
d_stop() {
- PID=$( cat "$_PIDFILE" 2> /dev/null ) || true
+ PID=$( cat "$PIDFILE" 2> /dev/null ) || true
- start-stop-daemon --stop --quiet --oknodo --pidfile "$_PIDFILE"
+ start-stop-daemon --stop --quiet --oknodo --pidfile "$PIDFILE"
rc="$?"
if test "$rc" -eq 2; then
esac
;;
status)
- status_of_proc -p "$_PIDFILE" "$DAEMON" "$NAME" && exit 0 || exit $?
+ status_of_proc -p "$PIDFILE" "$DAEMON" "$NAME" && exit 0 || exit $?
;;
restart|force-reload)
log_daemon_msg "Restarting $DESC" "$NAME"